I'm not too familiar with forums, so I'm not sure if I posted this in the right topic.
Ok now, this is a long shot, but I figured I would try asking for help anyhow.
I'm currently studying the topic syntax analyzer, focusing on LL(1) parsers. I understand the theories, how it works, etc. But as before, I am very weak in coding. So i searched Google for coding examples on LL(1) parsers and found these 6 links which I think relate to them:
Now, what I'm asking is which one of these six sites has the correct codes to run an LL(1) parser? If there are more than one, then the simplest would do. Explaining the code line-by-line would help too, if it's not too much a hassle.
(additional information: just to clarify, my definition of LL(1) parser, or what I was taught, is that the user inputs a grammar/language, then through executions of First and Follow rules a parsing table will be created. Then this table will be used for when the user inputs a string, and the user will find out if that string is valid or invalid for that grammar/parsing table. This process includes the stack/input/output table. Now I'm trying to find an example of a code for this and after searching through several code examples, I've narrowed it down to these 6 codes but I'm not quite sure which one is the right one, and/or the simplest one.
I've actually tried copy-pasting all these codes on Code::Blocks and I can't seem to get it to build and/or run properly, but that's a different topic)
(p.s: I apologize in advance if I am in the wrong topic, or if I'm not allowed to ask questions like this. Cheers)
Page 1 of 1
1 Replies - 9608 Views - Last Post: 11 July 2011 - 06:13 AM
Replies To: LL(1) parser code links
Re: LL(1) parser code links
Posted 11 July 2011 - 06:13 AM
I would suggest that after you read the links and study your text book you start writing the code for the parser. When you have trouble with your code then come back and post your code and ask questions based on your code. Just taking code from the internet, that you do not understand anyway, will not help you learn to code. You say you understand the concepts of your problem, so take that knowledge and get to work.
This post has been edited by jimblumberg: 11 July 2011 - 06:13 AM
Page 1 of 1