permaculture playing cards*
The moose likes Meaningless Drivel and the fly likes Will this be a reality in the future? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Other » Meaningless Drivel
Bookmark "Will this be a reality in the future?" Watch "Will this be a reality in the future?" New topic
Author

Will this be a reality in the future?

Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9243
    
    1

Will there be a programming language where programming is like writing an essay? I.e., I write a paragraph in simple English for a task which when compiled does what I want.


SCJP 1.4, SCWCD 1.4 - Hints for you, SCBCD Hints - Demnachst, SCDJWS - Auch Demnachst
Did a rm -R / to find out that I lost my entire Linux installation!
Ayub ali khan
Ranch Hand

Joined: Oct 20, 2005
Posts: 379
    
    2
Yes why not. Anything is possible !!! Long live JAVA !!!


SCEA part I,TOGAF Foundation
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39537
    
  27
I don't know about simple, but you might want to take a look at Cobol. It comes closer to being written text than any other language I've seen.


Ping & DNS - updated with new look and Ping home screen widget
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9243
    
    1

I'm just meaning something like this, say I have to loop through 10 times and print something on the screen. For this I just write in my own english "loop through this 10 times and print on the screen..." something like this...
Nitesh Kant
Bartender

Joined: Feb 25, 2007
Posts: 1638

[I had this typed since sometime, so it may be a little offtrack]
Even if it happens, would you like to maintain/debug such a code? Considering the nuances that english language has, you can think of the headache it can become.
Moreover, i think learning english language completely is tougher than learning JAVA or other language. Imagine a situation where in you are reading a code(uhmm essay) of a guy who knows very good english!!!
[ November 28, 2007: Message edited by: Nitesh Kant ]

apigee, a better way to API!
Peter Rooke
Ranch Hand

Joined: Oct 21, 2004
Posts: 794

Ever heard of the term CandyGrammar?

candygrammar

A programming-language grammar that is mostly syntactic sugar; the term is also a play on `candygram'. COBOL, Apple's Hypertalk language, and a lot of the so-called `4GL' database languages share this property. The usual intent of such designs is that they be as English-like as possible, on the theory that they will then be easier for unskilled people to program. This intention comes to grief on the reality that syntax isn't what makes programming hard; it's the mental effort and organization required to specify an algorithm precisely that costs. Thus the invariable result is that `candygrammar' languages are just as difficult to program in as terser ones, and far more painful for the experienced hacker.


Regards Pete
Frank Silbermann
Ranch Hand

Joined: Jun 06, 2002
Posts: 1379
Originally posted by Peter Rooke:
Ever heard of the term CandyGrammar?

But that's not what we're talking about. He's asking about a language in which you write in imprecise, ambiguous English, and the compiler figures out what the writer meant to ask for (or better yet, what the programmer should have intended for the computer to do.
Bert Bates
author
Sheriff

Joined: Oct 14, 2002
Posts: 8764
    
    5
This reminds me of an old email entitled:

"Proposed Additions to the PDP-11 Instruction Set"

It included such candidates as:

BBW - branch both ways
BEW - branch either way
D0CF - divide by 0 then catch fire

and of course,

DMNS - do what I mean, not what I say


Spot false dilemmas now, ask me how!
(If you're not on the edge, you're taking up too much room.)
George Harris
Ranch Hand

Joined: May 05, 2003
Posts: 84
I don't understand why anyone would ever want to do anything using the Engligh language. Most programmers I know hate documenting because writing in English bites. I worked for an AI company that was working with 'Natural Language' and it was the most difficult thing to use. Not only did you have to use perfect english, the type most English professors wouldn't use, it also required a very verbose description to get anything to work.

In terms of programming, I believe in the KISS principle. But English (and most natural languages) are more of the KISS MY A**.
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15286
    
    6

I don't understand why anyone would ever want to do anything using the Engligh language. Most programmers I know hate documenting because writing in English bites.

I rather like English. I am a bit biased though being a (North) American and English being my primary language.


GenRocket - A Test Data Generation Platform
Marc Peabody
pie sneak
Sheriff

Joined: Feb 05, 2003
Posts: 4727

Originally posted by Jothi Shankar Kumar Sankararaj:
"loop through this 10 times and print on the screen..." something like this...

There would still have to be some rigid standards on how the English should be structured. As everyone is saying, human language is fuzzy. Half the time we don't understand each other, so why should we expect a computer to be any different? And even if the computer happens to understand what you intended, who's to say that the next human to read your "code" interprets it correctly? Ever have someone explain something to you but you weren't sure of what was really intended?

For example:
A: "Go two more lights and then turn left."
B: "Wait, do you mean I should turn left at the second light?"
A: "No, take the first left after the light."

If you're simply looking for a way to code more like English, you should Google for stuff on Domain Specific Languages (DSLs), which are fairly popular with scripting languages. For instance, your loop statement could be written similar to 10.times{ print "something" } in some languages.


A good workman is known by his tools.
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper

Joined: Aug 26, 2006
Posts: 4968

Well, personally speaking, I've always felt my code reads like a Shakespearian play. Most of my co-horts agree; of course, I think that just means they don't understand it.

-Cameron
Sachin Patil
Ranch Hand

Joined: Jul 08, 2002
Posts: 118

Dont you think BPEL is taking us that way?


A tool that's lost its purpose makes a great toy.
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9243
    
    1

By the way, what is BPEL?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39537
    
  27
Dont you think BPEL is taking us that way?

Being XML, and not linear in its flow, I don't think any non-trivial BPEL process is easily readable.

By the way, what is BPEL?

BPEL and Java introduction
ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
Originally posted by Jothi Shankar Kumar Sankararaj:
something like this...


That would be a good feature.
 
wood burning stoves
 
subject: Will this be a reality in the future?
 
Similar Threads
Does Palm device support Personal Java
How You Guys learn Java from A Book
OO and AOP
Servlets Only Web Application
Need suggestion on choosing a nice book about AWT - reg.