I have been using perl for some time now. I want to know how I can run the following operation in perl:
subtract(40)(20)
To get the result:
20
I think I would have to look at custom parsing techniques for Perl. This is what I am looking at right now:
and http://www.perl.com/pub/2012/10/an-overview-of-lexing-and-parsing.html
Now, I am not sure what to look for or what to do. Any help on HOW to go about this, WHAT to read would be appreciated. Please be clear. Thank you.
If you can live with the additions of a sigil and an arrow, you could curry
subtractas inCall it as in
If the arrow is acceptable but not the sigil, recast
subtractasInvocation in this case looks like