optimal parsing using dynamic programming

  • Status: Closed
  • Præmier: $25
  • Modtagne indlæg: 2
  • Vinder: commaster90

Konkurrence Instruktioner

I need the program to get a list of numbers and make the optimal parse tree as following.
$ ./myprogram 10 10 11 12 5 3 16 17 19 4 8
((x(x(xx)))((xx)(x(xx)))) 5562

5562 is scalar multipication.
the first 10 is the number of integer parameter.
10 11 12 5 3 16 17 19 4 8 are the numbers passing to the programming to build the tree.
I also need comments to understand how its been coded. thank you

Anbefalede Evner

Arbejdsgiverfeedback

“Communication with him is very good and easy.”

Profilbillede liefde2010, Canada.

Bedste indlæg fra denne konkurrence

Se flere indlæg

Offentlig Præciserings Opslagstavle

  • ingund
    ingund
    • 3 uger siden

    let's give another try .

    • 3 uger siden
  • sakhawat2
    sakhawat2
    • 3 uger siden

    10 10 11 12 5 3 16 17 19 4 8

    From there, the integer inputs are:
    10 11 12 5 3 16 17 19 4 8
    There are 10 ints here.

    The parse formula is:
    ((x(x(xx)))((xx)(x(xx))))
    9 ints. Which 9 do we choose?

    • 3 uger siden
    1. liefde2010
      Konkurrenceafholder
      • 3 uger siden

      Its based on the tree. U can see an example below.
      https://drive.google.com/file/d/11BIlULcbk5HnAb93y1cnNbLA1R89MVu4/view?usp=drivesdk

      • 3 uger siden
  • StrongDecs
    StrongDecs
    • 3 uger siden

    #increaseprize

    • 3 uger siden
    1. liefde2010
      Konkurrenceafholder
      • 3 uger siden

      How much?
      How long does it take?

      • 3 uger siden
    2. StrongDecs
      StrongDecs
      • 3 uger siden

      I could describe my experience over similar tree development in the private messages, let's message to discuss the details

      • 3 uger siden
  • ingund
    ingund
    • 3 uger siden

    Hi , I would like to help you but I can't understand what is the formula:

    $ ./myprogram 10 10 11 12 5 3 16 17 19 4 8

    ((x(x(xx)))((xx)(x(xx)))) 5562
    #1: ((11*(12*(5*3)))*((16*17)(19*(4*8)))) * 5562
    #2: ((11(12(53)))((1617)(19(48)))) * 5562

    how should be output?

    Kind Regards

    • 3 uger siden
    1. liefde2010
      Konkurrenceafholder
      • 3 uger siden

      ((x(x(xx)))((xx)(x(xx)))) 5562
      This is the result the program should print

      • 3 uger siden
    2. liefde2010
      Konkurrenceafholder
      • 3 uger siden

      So ((x(x(xx)))((xx)(x(xx)))) is the way of parsing.
      and 5562 is scalar multipication.

      • 3 uger siden

Vis flere kommentarer

Sådan kommer du i gang med konkurrencer

  • Opret din konkurrence

    Opret din konkurrence Hurtigt og nemt

  • Få tonsvis af indlæg

    Få tonsvis af indlæg Fra hele verden

  • Tildel det bedste indlæg

    Tildel det bedste indlæg Download filerne - Nemt!

Opret en Konkurrence Nu eller slut dig til os i dag!