Home > Back-end >  Reverse polish expression problem solving algorithm
Reverse polish expression problem solving algorithm

Time:01-06

Algorithm problems
1. Enter * 12.0 + 11.0 + 24.0 35.0
2. Return to exp () * exp ()
Question 1: why return exp function will skip the cin the statement, is not called exp once, do a cin!
Question 2: for example, figure 2 sample input, for the first time to return to exp () * exp (), the inside of the first exp parameter is (35) + 11 12 + 24
Integrity inquire, thank you for your

CodePudding user response:

This is recursive, recursive calls itself is a process or a few, it is not skip itself cin, he is over the previous cin, although that is executed statements is the same but in different execution process,
  • Related