I’m beginner and I need a little help. I have to make RPN (postfix) calculator using stack which is implemented by singly linked list in C. Now I found that but in C++ and I’m having trouble translating it to C. Can you help me getting things to work? I have started from http://www.mediafire.com/view/q833x5sic8eq4sx/from_c__.txt and using a little code from http://www.mediafire.com/view/ewz9so6999ig5x0/using_c.txt I get to http://www.mediafire.com/view/qesca0cg0vzjzac/to_this_in_c.txt code and it debugs but when I enter anything in console it crashes and gives me some assembly code I’m using VS C++ 2010. Please help me to fix this, I can’t find what’s wrong.
Jump to Post
So, you are using other people's code? Have you tried implementing it yourself? Do that, and we can help you. Also, you will learn a lot more about what you are doing. An RPN calculator is effectively a stack machine. You can use the singly-linked list pattern in either C …
Jump to Post
Then a singly-linked list where you insert at the top of the list (push), and remove from there as well (pop), will give you a nice stack behavior. You can use an array as well, inserting and removing from the bottom of the array. Either will work, though the array …
All 5 RepliesReply to this topic
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.