[sclug] COBOL

Tom Dawes-Gamble tmdg at tmdg.co.uk
Sat Oct 25 09:05:38 UTC 2003


On Mon, 2003-05-12 at 14:02, Daniel Lower wrote:

> 
>  COBOL (yuck), 

Well like most things thats a matter of opinion.  
My first programming job was as a COBOL programmer.

Some people argue that COBOL is verbose.  Well yes it was but with 
the Micro Focus COBOL the Famous "Hello World" program could be written
in COBOL as :-

  display "hello world".

In C it's more like

main(){print("hello world\n");}

Then of course there is the precision you can achieve.

If you multiply 1111111111.1111  by 5.5555 and work the answer using pen
and paper you get the answer 6172777777.77771605.  

If you do the calculation in COBOL you get the same answer.  However, if
you do it in C you get he wrong answer.

Then there is I/O.  C has no I/0 it's all provided by functions and
system calls. COBOL has I/O as part of the Language.

Having had the Job of Migrating COBOL programs across various platforms
I would say that it is the easiest language to write Machine independent
code/programs.

Whilst I wouldn't choose COBOL today there is nothing wrong with the
Language. 

Regards,
Tom


-- 
There are 10 sorts of people.
Those that understand binary and those that don't!

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.tmdg.co.uk/pipermail/sclug/attachments/20030512/2a75ffa0/attachment.bin


More information about the Sclug mailing list