Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Infix postfix

Options
  • 12-11-2005 12:46am
    #1
    Closed Accounts Posts: 488 ✭✭


    Any help would be appreciated.

    So I am thinking I need a StreamTokenizer to get each number/operator etc, should they go on an array and find some way to loop through figureing out precendense.

    Maybe I am wrong any hints.


Comments

  • Registered Users Posts: 19,396 ✭✭✭✭Karoma


    Firstly,WTF? I'm assuming that you mean that you have to write a program to convert from Infix to Postfix...?
    Is it meant to be one-way or are you to convert Postfix to Infix also?
    Is this for college? I vaguely remember writing something along these lines for college, implementing a stack-based solution.. If it is for college, then chances are you'll have been given an idea of what sort of solution the lecturer wants (Based on the design brief, or previous/recently covered topics.)


  • Closed Accounts Posts: 488 ✭✭watsgone


    Oh sorry, yes I meant to convert from Infix to postfix.
    It is for college and it is one way.


Advertisement