Programming and Natural languages
Published Thursday, October 27, 2005 by shabda | E-mail this post
Programming and lateral languages.
Programming languages are like your everyday English- or Spanish, or hindi if you prefer. All languages C, Java, Hindi and English come with their own syntax, rules, grammar, constructs and idiosyncrasies. All languages have their strengths Latin for the courts, Pidgin English for the common folk, Java for the web and C for systems.
“I ate a mango” is syntactically correct and compiles with the English compiler V 3.1 of your head. But try running Hindi, Spanish, or Java compiler on it and you are sure to get an error message. A program written in java won’t compile with an English compiler. “I ate a play” is syntactically incorrect even with the English compiler. Did you eat or did you play. (It will surely violate some rule of English, but my grammar is too poor to find out what). “I ate a man” may be syntactically correct but has a logical error. It compiles, it does violate no rule of English grammar. But really are you a cannibal?
Really is a programming language anything other than a natural language minus redundancy and verboseness and no ambiguity. How long before we are able to program in English. Or will it be the other way. We learn to talk in Java?
0 Responses to “Programming and Natural languages”
Leave a Reply