in reply to Re: Converting words to numbers with HOP::Parser
in thread Converting words to numbers with HOP::Parser
I missed that module when I was searching for it on the CPAN. Bummer.
I find it interesting what extremely different styles our solutions have. Your's is quite procedural. Using a parser is declarative. What I find interesting about the latter is how one can pretty much rearrange all of the declarative portions of the parser and things still work as intended. This gives one a lot of flexibility.
It's also (relatively) easy to extend. If I want to turn it into a calculator which responds appropriately to "divide three by seven and add twelve point two", I can do that. Further, it would merely build on what's there and nothing else would need to be touched. I wonder how feasible this is with a procedural model.
In any event, your speculation was correct. My post was primarily intended to show off the power of the HOP::Parser as opposed to "hey, let's turn words into numbers!"
Cheers,
Ovid
New address of my CGI Course.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Converting words to numbers with HOP::Parser
by eric256 (Parson) on Nov 06, 2005 at 23:27 UTC |