SCOUG-Programming Mailing List Archives
Return to [ 08 | 
August | 
2003 ]
<< Previous Message << 
 
 
 
Content Type:   text/plain 
Tom Novelli wrote:  
>   
> > But English would work.  
>   
> It works for describing algorithms to humans.. math,  
> flowcharts and diagrams help.. but it takes Real(tm)  
> 100% Natural Intelligence to understand English. . . .  
> So you have to impose some serious restrictions on  
> English, and you end up with COBOL or Pascal or BASIC,  
> which definitely leave something to be desired!  
 
A quick tangent -- I found Pascal to be a reasonably robust language.   
There are several versions of Pascal available for OS/2, most of them  
free.  One is a clone of Borland Pascal.  The major Borland Pascal  
problem for me was a maximum string length of 255 characters (the  
strings had an associated length byte rather than being null  
terminated); the OS/2 clone allows long strings.  
 
Now back to English.  
 
I want to clarify something.  When I say English can be a programming  
language, I mean it in the same way that English may be used in the  
medical profession or in the field of law.  Certainly no one is  
expecting a compiler to create a program which will solve the world's  
nutritional problems if it is told to compile the following:  
 
  You ain't nothin' but a hound dog,  
  Rockin' all the time,  
  You ain't nothin' but a hound dog,  
  Rockin' all the time,  
  Yeah, you ain't never caught a rabbit,  
  You ain't no friend of mine.  
 
In short, not every English phrase is a program.  I can write  
non-programs in COBOL, PL/I and assembler too.  
 
Take any English sentence that is part of a program.  Parse the sentence  
(a non-trivial task).  Call the necessary subroutines.  
 
Sounds like COBOL, yes?  But a COBOL sentence takes a rigid syntactical  
form; I think that we've learned enough in the past 40 years to allow a  
more general free-flowing syntax.  
 
All I'm suggesting is one addition -- create a parser that understands a  
"reasonable" English sentence.  There is existing research in this field  
but what I've read basically uses just brute force methods.  I haven't  
checked for any patents.  Near as I can figure, you first create a logic  
tree of the words and then analyze the content.  
 
The output need not be an executable.  Rather, the program could create  
source code in an existing computer language -- perhaps RPG, perhaps  
SQL, perhaps Rexx, perhaps PL/I, whatever.  The program could, based on  
the English it analyzed, make a determination as to which computer  
language it would use.  
 
So you might want to call this the English Preprocessor.  
 
And I think it belongs in the new HLL we're discussing.  
 
- Peter  
 
 
=====================================================  
 
To unsubscribe from this list, send an email message  
to "steward@scoug.com". In the body of the message,  
put the command "unsubscribe scoug-programming".  
 
For problems, contact the list owner at  
"rollin@scoug.com".  
 
=====================================================  
 
  
<< Previous Message << 
Return to [ 08 | 
August | 
2003 ] 
  
  
The Southern California OS/2 User Group
 P.O. Box 26904
 Santa Ana, CA  92799-6904, USA
Copyright 2001 the Southern California OS/2 User Group.  ALL RIGHTS 
RESERVED. 
 
SCOUG, Warp Expo West, and Warpfest are trademarks of the Southern California OS/2 User Group.
OS/2, Workplace Shell, and IBM are registered trademarks of International 
Business Machines Corporation.
All other trademarks remain the property of their respective owners.
 
 |