> 5 billion lines of new COBOL code are written every year. Are you sure about that? Sounds like rather a lot.
It doesn't sound too off to me - I can believe that there are a million legacy COBOL users around and that each writes on average a thousand lines of maintenance code each year. Or maybe fewer users and more lines - COBOL is a notoriously verbose language.
Don't hate COBOL until you've tried it
121–130 of 139 posts
Re: Don't hate COBOL until you've tried it
#122Earlier quoted context omitted.
> one of the biggest productivity improvements in the history of programming, comparable to the introduction of Java and VM-based programs in the 1990s. If languages like Smalltalk, APL and Lisp aren't counted, then sure, Java was big productivity boost in the history of programming.
I think that the reach of a language need to be considered, as influential and lovable those language might be most of the effect they had was by influencing other languages.
Einstein got the Nobel for the photoelectric effect, which we take advantage of continuously every day. I'd say that was influential.
Re: Don't hate COBOL until you've tried it
#123But programming evolved and Cobol did not evolve at the speed of the times. In 1968 (Cobol-68) it was already outdated compared to IBM PL/1 (a big monster of a language, similar but much more powerful).
And in 2017, "Try COBOL"? You mean, try a language where I need to deal with record access as if I were rolling my own DBMS system, with almost no module support, and copious need for copy/paste of code at every file (little chance of code reuse)? Where separation of concerns is almost zero?
No, i think writing in INTERCAL-72, Brainf_ck or LOLCODE would be more fun.
Re: Don't hate COBOL until you've tried it
#124What I do find interesting is the attitude of some who classify COBOL as ancient (etc) and have not yet realised that there are a number of major modern languages that are the spiritual descendants of COBOL. These being ADA, Java, C#, C++ and the rest of their ilk.
They each have a place to play in the computing world, but they each are the wrong language for many purposes. Too oft I find, many programmers know one or two languages and they are the worse off for that. Different languages give different insights into specific problem domains. Every language allows some things to be done easily and other things to be done hard.
Decades ago now, as CompSci undergraduates, we were expected to learn (or at least use) every available language, from Fortran to COBOL, Algol 60 to Lisp, assembler to Simula, Snobol to Pascal, Basic to Algol 68, etc., etc., etc.
These days, undergraduates seem to be taught one or two languages and that's it. It shows up in their later inability to solve certain kinds of problems in a problem space specific way.
Re: Don't hate COBOL until you've tried it
#125I worked for one of those companies using COBOL. This strikes me: > Once I discovered what the problem was, the fix was easy: I deleted one character of white space from the beginning of line 19, which put the period at column 72. Although I'd never encountered it before, this was such a common bug that many mainframe COBOL programmers would tape a piece of thread between columns 72 and 73 on their terminals. Why wou…
Re: Don't hate COBOL until you've tried it
#126Dates fixed in a YYYYMMDD representation. Seems like very ad-hoc representation. If you need "sixty days before such and such a date", ouch. Shipping price conforms to a "pic 99v99". So what happens if a really big shipment needs to be made for which $100.47 needs to be charged?
Having said that, situations like would come up sometimes. You really did have to decide ahead of time how big field could be. You could leave extra filler bytes in your tables (literally named "filler") but it was still a big hassle to deal with.
Re: Don't hate COBOL until you've tried it
#127I worked for one of those companies using COBOL. This strikes me: > Once I discovered what the problem was, the fix was easy: I deleted one character of white space from the beginning of line 19, which put the period at column 72. Although I'd never encountered it before, this was such a common bug that many mainframe COBOL programmers would tape a piece of thread between columns 72 and 73 on their terminals. Why wou…
This is trivially solved by linters.
Re: Don't hate COBOL until you've tried it
#128Shouldn't it be possible to convert COBOL to C C++ LLVM IR or even WebASM?
Re: Don't hate COBOL until you've tried it
#129I have not used COBOL for 30 years but the language deserves respect. The transition from assembler to COBOL was one of the biggest productivity improvements in the history of programming, comparable to the introduction of Java and VM-based programs in the 1990s. COBOL is still pretty efficient for tasks like scanning data on magnetic tapes--not that most of us do that any more. In fact it was pretty good for any pro…
Fortran's older and Lisp is as old (it can be argued about whether COBOL or Lisp are older). Fortran and Lisp seem to have held up much better. ALGOL is another contemporary, and arguably the one that has the biggest impact on popular languages.
I'm also a big FORTRAN fan, especially the VAX-FORTRAN variant DEC introduced in the 1980s. It was great for numerical analysis but also included library calls to access the operating system, much like C. Some of us were late to the Unix party, so this was a huge step forward.
Re: Don't hate COBOL until you've tried it
#130I once had to port COBOL to Java. It presented some interesting problems because of EBCDIC, nibbles, non IEEE arithmetic, and alien data formats. A long story short: there are problems where COBOL is better suited than Java.
Were you also moving from a mainframe to a server? I would have thought that Java on a mainframe would handle EBCDIC just fine, but I have never tried it.