🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.lang.modula2
15 messages
15 total messages Started by Steven William Carvaines Thu, 18 Jan 1996 12:38
Do any employers use Modula-2?
#3135
Author: Steven William Carvaines
Date: Thu, 18 Jan 1996 12:38
18 lines
1304 bytes
   As part of our computer science curriculum at Ohio State, we learn
Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
checked with a few potential employers, and none of them need anyone with
Modula-2 experience.  Most don't even know what Modula-2 is.  I've been
told by professors that learning Modula-2 is a stepping stone for learning
other languages.  I don't buy that.  So my question is this:  has anyone
come across an employer who uses Modula-2?  It would be a shame to become
proficient in it and never use it again.

Thanks,

Steve

******************************************************************
* Steven William Carvaines (student - The Ohio State University) *
* E-mail:  carvaines.1@osu.edu                                   *
*          carvaine@cis.ohio-state.edu                           *
******************************************************************
Re: Do any employers use Modula-2?
#3147
Author: Martin Tom Brown
Date: Fri, 19 Jan 1996 08:29
33 lines
2077 bytes
In article <carvaines.1-1801961238310001@slip7-4.acs.ohio-state.edu>
           carvaines.1@postbox.acs.ohio-state.edu
           "Steven William Carvaines" writes:

>    As part of our computer science curriculum at Ohio State, we learn
> Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
> checked with a few potential employers, and none of them need anyone with
> Modula-2 experience.  Most don't even know what Modula-2 is.  I've been
> told by professors that learning Modula-2 is a stepping stone for learning
> other languages.  I don't buy that.  

You should - it is helpful to learn a few languages with different
characteristics even if you will ultimately specialise in just one.
Modula 2 is a well specified minimallist language, with clean semantics
so to put it another way- if you are incapable of learning M2 
you have *no* chance with other more fickle languages like C/C++. 

> So my question is this:  
> has anyone come across an employer who uses Modula-2?  

Yes. It gets used for some embedded control applications where
there is serious concern about correctness and reliability.
My previous employer used mainly Modula2.

> It would be a shame to become proficient in it and never use it again.

It strikes me as bit strange and confusing for the students to teach 
M2 and then Pascal, but perhaps there is some rationale behind it.

Regards,
-- 
Martin Brown  <martin@nezumi.demon.co.uk>     __                CIS: 71651,470
Scientific Software Consultancy             /^,,)__/
Re: Do any employers use Modula-2?
#3141
Author: Ned
Date: Fri, 19 Jan 1996 13:07
38 lines
2111 bytes
Steve Carvaines wrote:
>
>    As part of our computer science curriculum at Ohio State, we learn
> Modula-2 as one of our 'first' languages (we also learn Pascal). I've
> checked with a few potential employers, and none of them need anyone with
> Modula-2 experience. Most don't even know what Modula-2 is. I've been
> told by professors that learning Modula-2 is a stepping stone for learning
> other languages. I don't buy that.

Yair, right. They don't know what they're talking about.

When you start in on other languages, you'll find that you
understand all the concepts and all you have to do is learn
the keywords and the syntax. Nice and easy. Pascal and Modula
*make* it easy because they don't clutter your learning mind
with lots of stuff irrelevant to the central issues of
programming. And there is *lots* of it.

When you get to languages like C, your error rate will go
through the roof. It might get so bad that you'll spend more
time debugging than anything else. If you had to start with
a language like that, your studies would be even harder and
more frustrating than they are now.

Modula-2 is gets the three T's: trim, taut, terrific. It's
small, elegant (wait for it: you'll learn what that means),
flexible, powerful and safe.

It's a damned shame that more employers don't use it. In a lot
of cases, they'd do better business. That those prospective
employers you mentioned don't use it probably indicates their
ignorance. And maybe weakness in their product.

That more employers don't use it is *not* a good reason for
making you learn programming principles *and* the specifics
of some error-prone syntax horror like C at the same time.

Ned
Re: Do any employers use Modula-2?
#3144
Author: Bill Seurer
Date: Fri, 19 Jan 1996 17:03
25 lines
1843 bytes
If you are a CompSci student you should learn AS MANY languages as you can
whether or not you ever use them in your "real" job someday or not.  Why?
Because every language has its own way of looking at problems and if you
learn several of them whatever language you eventually use you will be
able to come up with better solutions.  Also, the more languages you learn
now the easier it will be to learn any new languages in the fuuture.

Way too many people go to college looking to be trained for a job.  That
shouldn't be your goal.  You should learn as much about your chosen
profession as you can.  In our fast changing world whatever language
is tops today could be on the outs by the time you graduate anyway.

I learned Modula-2, Pascal, and C when I was in college and was exposed
to Simula-67, Ada, COBOL, and several others.  I now wish I'd spent more
time with those others.  Most of my programming is in C++ and Modula-2
now but the mix of experience (I think) gives me an advantage over those
who have had only C/C++ in college.

As for employers that use Modula-2 there are several groups here at IBM
in Rochester that use it.  And some groups at other sites doing work for
us use it as well.
-- 

- Bill Seurer     ID Tools and Compiler Development      IBM Rochester, MN
  Business: BillSeurer@vnet.ibm.com               Home: BillSeurer@aol.com
Re: Do any employers use Modula-2?
#3146
Author: Douglas Evan Cook
Date: Fri, 19 Jan 1996 18:32
54 lines
3889 bytes
On Thu, 18 Jan 1996, Steven William Carvaines wrote:

>    As part of our computer science curriculum at Ohio State, we learn
> Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
> checked with a few potential employers, and none of them need anyone with
> Modula-2 experience.  Most don't even know what Modula-2 is.  I've been
> told by professors that learning Modula-2 is a stepping stone for learning
> other languages.  I don't buy that.  So my question is this:  has anyone
> come across an employer who uses Modula-2?  It would be a shame to become
> proficient in it and never use it again.
> 
> Thanks,
> 
> Steve

Although the government <says> it uses Ada, that really isn't the whole
story.  Ada is such a HUGE language, it takes years to compile.  So the
place where I worked looked for a good substitute that produces good solid
transportable code in which they could prototype their system, and so all
of the coding I did was in Modula II.  After I was done, somebody else
went through and translated, line for line, my M2 programs into the Ada
that most of the government seems to want.  We kept the M2 versions, and
they are used as well, but we had to create Ada versions for the
departments that only used Ada.  We used M2 as the original development
platform because it is self-documenting (well-written code reads like a
good novel in M2, and comments are usually not needed within modules),
quick compiling, and not prone to errors.  I really enjoyed the language. 
It is professional-level in capability, portability, and object code
quality, but (as opposed to C++) it is a very logical, simple,
straightforward language that encourages good programming techniques, and
(as opposed to Ada) has a quick debug-compile-test cycle.  Until I
graduate (at which point I don't have a clue where I will be working), M2
will be my primary employment language since I have a fairly firm offer of
summer employment at this government operation until I graduate.  After
that, I hope M2 will have made a comeback because I still feel it is one
of the best languages around and I enjoy working in it.  As a stepping
stone, it is the best, and I highly recommend becoming and expert at it,
because the techniques you learn in M2 are excellent for all languages. 
M2 just encourages them more.  So learn it.  Even if you never use it in 
the work force, it will improve your code quality in all of your other 
languages if you let it.  For example, treat Pascal as if it were 
case-sensitive and your programs will look neater.  Structure your code 
the way M2 forces you to when you are programming in C or Pascal and it 
will be organized much better.  And don't use strange programming 
techniques that can't be done in M2, because if they can't be done in M2 
(but can be done in C++), it will probably take someone else a long time 
to figure out what you are doing (I'm talking about weird stuff with 
post- and pre-increment, pointers, etc., like obfuscated code).

=============================================================
Douglas Cook, undergraduate in Computer Science at BYU
-------------------------------------------------------------
*REAL* programmers use COPY CON PROGRAM.EXE
=============================================================
Re: Do any employers use Modula-2?
#3155
Author: //
Date: Sun, 21 Jan 1996 14:43
61 lines
2559 bytes
On 18 Jan 96 12:38 am, carvaines.1@postbox.acs.ohio-state.edu (Steven 
William Carvaines) writes: 
> As part of our computer science curriculum at Ohio State, we learn 
  > 
Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
  > 
checked with a few potential employers, and none of them need anyone 
with 
  > 
Modula-2 experience.  Most don't even know what Modula-2 is.  I've been
  > 
told by professors that learning Modula-2 is a stepping stone for 
learning 
  > 
other languages.  I don't buy that.  So my question is this:  has anyone
  > 
come across an employer who uses Modula-2? It would be a shame to become
  > 
proficient in it and never use it again.
  > 

  > 
Thanks,
  > 

  > 
Steve
  > 

  > 

Well, we do. So does Boeing, McDonnell Douglas (I think) and a number of
military and aviations developers who need compact executables and code 
reliablility (something that C has a difficult time providing). 

And yes, it's a stepping stone. Have you ever seen C code from a student
who only knows C? I have, and it's ugly, and unmaintainable. Modula-2 
gives you something to compare with - it's readable in nature (i.e. you 
have to try to make it hard to read), and quite strict, so the compiler 
lets you know when you're doing something that's potentially disastrous.
When they give you C in the follwing year, you will quickly develop an 
appreciation for readable code that should carry on into future 
languages. 

For this reason, we don't even _consider_ hiring someone who does not 
have experience in eithe Modula-2 or Pascal. The people whom we made 
exceptions for all produced garbage, even in their 'native' language. I 
suspect it's because they did not appreciate the fact that other might 
have to read to debug their code... 


Cheers,

Jan

------------------------------------------------------------------------
//   Centurion Services & Wholesale     //
//   "Quality from the Start"           //
//   Fax: (604) 279-1800                //
//   centurion@infomatch.com            //
------------------------------------------------------------------------
Re: Do any employers use Modula-2?
#3162
Author: "David Collier"
Date: Mon, 22 Jan 1996 18:30
23 lines
1542 bytes
One:    Modula-2 is probably the best stepping stone to ADA. As related 
elsewhere in this discussion some government agencies require ADA 
programs. I understand tat the ADA environments that exist on a Pc, are 
slow and unwieldy.
If however you write your program in M2, it can be translated to ADA with 
little difficulty. And the clever ADA stuff you don't get to use that 
way, probably should be avoided anyway!

Two:    Treat Modula-2 as a "Conceptual language". If I am writing C, I 
think in Modula, but write in C. The result is clearer than going 
straight to C. There is little that you can do in C, but not in M2, and 
most of it is the stuff that makes C programs harder to read.

Off hand the only things I miss in MS, compared with C, are 

        A := B
        FOR loops including "WHILE"
        
Think of computer languages like human languages. Every time you learn a 
new one, you learn a new way to say things, and a few new neat concepts, 
and ways to understand. But in the end, expressing the ideas in your head 
is  pretty similar in most of them. And it you are dumb and tongue-tied 
in one, you wont be better in another.
Re: Do any employers use Modula-2?
#3171
Author: Fritz W Feuerbacher
Date: Tue, 23 Jan 1996 16:37
16 lines
1478 bytes
Steven William Carvaines (carvaines.1@postbox.acs.ohio-state.edu) wrote:
:    As part of our computer science curriculum at Ohio State, we learn
: Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
: checked with a few potential employers, and none of them need anyone with
: Modula-2 experience.  Most don't even know what Modula-2 is.  I've been
: told by professors that learning Modula-2 is a stepping stone for learning
: other languages.  I don't buy that.  So my question is this:  has anyone
: come across an employer who uses Modula-2?  It would be a shame to become
: proficient in it and never use it again.

Modula-2 is an excellent language to learn with.  It will help a great deal
later when you go into software engineering in greater detail.  Modularity
is key to good project maintainability and reusability, at least thats 
what I keep reading in my Object oriented textbook.  Modula-2 is object 
based and is probably the best learning high level language there is in 
my opinion.
Re: Do any employers use Modula-2?
#3172
Author: Nisse.Husberg
Date: Tue, 23 Jan 1996 18:13
39 lines
2361 bytes
In article <4do539$h2b@lugb.latrobe.edu.au> cscedl@lux.latrobe.edu.au (Ned) writes:


> Modula-2 is gets the three T's: trim, taut, terrific. It's
> small, elegant (wait for it: you'll learn what that means),
> flexible, powerful and safe.
> 
> It's a damned shame that more employers don't use it. In a lot
> of cases, they'd do better business. That those prospective
> employers you mentioned don't use it probably indicates their
> ignorance. And maybe weakness in their product.
> 
> That more employers don't use it is *not* a good reason for
> making you learn programming principles *and* the specifics
> of some error-prone syntax horror like C at the same time.

You're quite right ! I'm working in a fairly important project
building analyzers to find errors in telecomm programs and we are
using C++. However, we spend more time on searching for errors than
actually programming. The damned thing writes randomly everywhere in
the memory ! Now we are trying to install bounds checkers to catch
these errors which would be no problem for a decent language like
Modula-2. In fact our employer is considering moving away from C++ to
Modula-2 or some other safer language. 

In fact one should not use C for anything else than toys. 

Employers do not know much about programming. If they learn about the
waste of time and the horrible lack of security in C and C++, they
hardly would object to using better languages. By the way, C did not
make it to "real" programming at once either. It was used mainly by
academics for 20 years at first.

I have put Garden Points Modula-2 and Oberon-2 in my Linux
machine. They seem quite professional and are supported if you pay the
license fee. Seem to work OK in the Linux environment with some
support in gdb too.

Nisse
Re: Do any employers use Modula-2?
#3183
Author: Antonio Vieiro Varela
Date: Wed, 24 Jan 1996 17:39
48 lines
3022 bytes
>    As part of our computer science curriculum at Ohio State, we learn
> Modula-2 as one of our 'first' languages (we also learn Pascal).  I've
> checked with a few potential employers, and none of them need anyone with
> Modula-2 experience.  Most don't even know what Modula-2 is. [...]

I am a teacher at the Spanish "Open  University"  (U.N.E.D.  as we call it)
at Galicia  (the  rainy  north of Spain).  We use  Modula-2  as a  training
language at the first course of the equivalent to your "Computer  Science".

My pupils are  expected to learn the basics of computer  programming,  this
is, what an ARRAY is, what the  advantages of a RECORD are and how to use a
POINTER to make a list.

As they go ahead using  Modula-2, and after having used it for some time, I
tell them they *MUST* learn some other languages (C is a must, I think, but
there are some others).  Then they realize about some  *ADVANTAGES*  of the
Modula-2  language  over  the  new  ones  they  are  learning,  such as the
possibility of hidding the internals of a MODULE, not allowing a POINTER to
point to a  variable,  and lots of  others.  At the same  time,  they  also
notice which the *DISADVANTAGES* are.

After that step, this is, after having learnt "all" about some  programming
languages,  they will notice that each  language has its pros and cons, and
they  will use one or the  other  for  different  purposes,  selecting  the
language that best suits the problem.  For instance,  one can build part of
a program  using  Modula-2 and another part using C.  Then the parts can be
merged to get an only final program.

Furthermore,  although I've been using C for a longer time than Modula-2, I
can build  programs  faster and more safely using Modula-2 than using C, so
Modula-2 will be of great help for you at your work and studies.

So learn as much languages as you can and don't worry about how many people
use them.


			Happy learning,
			
					Antonio


P.S.: If you become a  professional  programmer,  then you will be learning

________________________________________________________________________________
			     Antonio Vieiro Varela
	    ( antonio@faraday.usc.es   http://faraday.usc.es:1024 )
		      Grupo de Electromagnetismo Aplicado
	   Facultad de Fisica. Universidad de Santiago de Compostela
Re: Do any employers use Modula-2?
#3184
Author: Antonio Vieiro Varela
Date: Wed, 24 Jan 1996 17:42
10 lines
1024 bytes
I meant you will be learning programming languages all the rest of your
life.

And please forgive my bad english.

________________________________________________________________________________
			     Antonio Vieiro Varela
	    ( antonio@faraday.usc.es   http://faraday.usc.es:1024 )
		      Grupo de Electromagnetismo Aplicado
	   Facultad de Fisica. Universidad de Santiago de Compostela
Re: Do any employers use Modula-2?
#3197
Author: Richard Terence Hillson
Date: Thu, 25 Jan 1996 14:21
7 lines
1214 bytes
Hi everybody, Rick Hillson here in England replying to Steve Carvaines message.  I am not 
aware of any employers that use Modula2 at the present time, but I don't care!  Do you know 
why?  Because I have just spent the last semester learning the functional language ML and 
quite frankly after tackling that, I'm happy to learn anything but ML.  ML is the language 
from hell!  No doubt when we start second semester next week and I begin to study Modula2 in 
detail, I will then to be able to start contributing relevant information to this newsgroup.  
Until then, if anyone wants to contact me, my Email is as follows --  cs95rth@brunel.ac.uk
Re: Do any employers use Modula-2?
#3192
Author: Fritz W Feuerbacher
Date: Thu, 25 Jan 1996 16:56
31 lines
2594 bytes
David Collier (dcollier@cix.compulink.co.uk) wrote:
: Think of computer languages like human languages. Every time you learn a 
: new one, you learn a new way to say things, and a few new neat concepts, 
: and ways to understand. But in the end, expressing the ideas in your head 
: is  pretty similar in most of them. And it you are dumb and tongue-tied 
: in one, you wont be better in another.

The reason that most high level imperative languages are the same is that
they are based on the same idea of the Von Neauman Architecture. i.e. the
concept of cpu, main memory, secondary storage, etc.  In other words you
have a memory matrix in which to store variables and instructions and you
need to fetch these things from memory to work on them, then when your done
you store them back into main memory for use later.  Other languages that are
declarative are totally different in the way they look at the architecture.
Another paradigm is object oriented programming which takes into 
consideration the data that is to be manipulated rather than the 
procedures and functions that manipulate them.  In object oriented 
languages we try to establish objects that work and return objects that 
we can let other objects use.  The objects are the data types.  We don't 
care how a data type handles the processing just as long as it does it.  
This ensures that we can reuse the object in future programs.  AN example 
would be an object called string.  We pass a string to it say: "Hello 
World" and then pass a command like "printstr".  The string data type 
itself says ok, someone gave me a string that is my type, and now they 
are telling me to print this string, let me look and see if I have a way 
to do that in my bag of tricks.  It looks and sure enough finds the 
necessary code to do it.  This links the data types with the operations 
that can be performed on them.  Hopefully by doing this, we can eliminate 
the need to re-write code that does the same thing over and over.  But, who's
to say that the original writer of the object and its methods did it the 
correct way?
Re: Do any employers use Modula-2?
#3204
Author: Jim Simmons
Date: Mon, 29 Jan 1996 07:11
76 lines
4850 bytes
On Fri, 19 Jan 1996, Douglas Evan Cook wrote:
>
>Although the government <says> it uses Ada, that really isn't the whole
>story.  Ada is such a HUGE language, it takes years to compile.  So the
>place where I worked looked for a good substitute that produces good solid
>transportable code in which they could prototype their system, and so all
>of the coding I did was in Modula II.  After I was done, somebody else
>went through and translated, line for line, my M2 programs into the Ada
>that most of the government seems to want.  We kept the M2 versions, and
>they are used as well, but we had to create Ada versions for the
>departments that only used Ada.

 Sounds like a typical government approach. And we pay for it!

>We used M2 as the original development
>platform because it is self-documenting (well-written code reads like a
>good novel in M2, and comments are usually not needed within modules),

 What shit!  Please do not perpetuate this attitude.
 Everyone knows their own code better than their own privates...
 until you forget, then it might as well be gibberish.

>quick compiling, and not prone to errors.  I really enjoyed the language. 
>It is professional-level in capability, portability, and object code
>quality, but (as opposed to C++) it is a very logical, simple,
>straightforward language that encourages good programming techniques, and
>(as opposed to Ada) has a quick debug-compile-test cycle.  Until I
                                                            ^^^^^^^^
>graduate (at which point I don't have a clue where I will be working), M2
 ^^^^^^^^^
 This explains the bit about non-commented code.
 You won't work for me with that attitude. Whatever language, be it C, C++
 Modula-2 or Pascal. It makes no difference.
 I hate to use the phrase, but I will anyway :-), "in the real world"
 you have to maintain code as well as write it, and so does everyone
 else.  No one ever seems to get around to writing real documentation
 outside the actual program (who said I was perfect :-( not me) and 
 even when they do it is rare technical documentation that gets anywhere
 near the level of detail you can reach in code.

>will be my primary employment language since I have a fairly firm offer of
>summer employment at this government operation until I graduate.  After
>that, I hope M2 will have made a comeback because I still feel it is one
>of the best languages around and I enjoy working in it.  As a stepping
>stone, it is the best, and I highly recommend becoming and expert at it,
>because the techniques you learn in M2 are excellent for all languages. 
>M2 just encourages them more.  So learn it.  Even if you never use it in 
>the work force, it will improve your code quality in all of your other 
>languages if you let it.  For example, treat Pascal as if it were 
>case-sensitive and your programs will look neater.  Structure your code 
>the way M2 forces you to when you are programming in C or Pascal and it 
>will be organized much better.  And don't use strange programming 
>techniques that can't be done in M2, because if they can't be done in M2 
>(but can be done in C++), it will probably take someone else a long time 
>to figure out what you are doing (I'm talking about weird stuff with 
>post- and pre-increment, pointers, etc., like obfuscated code).

 Maybe if it was commented it wouldn't be so mysterious.

 Sorry if this sounds a bit acerbic, but this is one very good yet
 very simple habit to get into, and the longer you code the more you
 will appreciate it - even if you are the only one that ever reads
 your own code. In a year's time it might as well have been a stranger.

 More and more employers nowadays are asking for samples of code, or
 even watching you produce code, before they hire you.
 Clean, well commented code can hardly do you any harm.

--
    *      *     *          
      * /\__O__/\  *        Jim Simmons, Lower Hutt, New Zealand 
       /   /    *\          jim@simmons.actrix.gen.nz            
    *      \\                
       *  \// *                                  __o      o 
           \\                     ____/\o__   _ |/<_     <\ 
            \\                      TriNZ    (_)| (_)   / > 
Re: Do any employers use Modula-2?
#3209
Author: Douglas Evan Cook
Date: Mon, 29 Jan 1996 21:27
100 lines
5900 bytes
On Mon, 29 Jan 1996, Jim Simmons wrote:

> On Fri, 19 Jan 1996, Douglas Evan Cook wrote:
> >
> >Although the government <says> it uses Ada, that really isn't the whole
> >story.  Ada is such a HUGE language, it takes years to compile.  So the
> >place where I worked looked for a good substitute that produces good solid
> >transportable code in which they could prototype their system, and so all
> >of the coding I did was in Modula II.  After I was done, somebody else
> >went through and translated, line for line, my M2 programs into the Ada
> >that most of the government seems to want.  We kept the M2 versions, and
> >they are used as well, but we had to create Ada versions for the
> >departments that only used Ada.
> 
>  Sounds like a typical government approach. And we pay for it!

I think it saves a whole lotta time, and when final products get written 
in both M2 and Ada, it makes sense to write the libraries first in the 
"lighter" language and then translate them, so you have libraries in both 
languages.  Seems good to me.  Sorry if you don't like it - got any 
better ideas?

> >We used M2 as the original development
> >platform because it is self-documenting (well-written code reads like a
> >good novel in M2, and comments are usually not needed within modules),
> 
>  What shit!  Please do not perpetuate this attitude.
>  Everyone knows their own code better than their own privates...
>  until you forget, then it might as well be gibberish.

I wasn't talking about MY code.  I went through over 40,000 lines of 
OTHER PEOPLE'S code while I was working, and my job was to port the 
program to Windows.  Just looking at the well written code (good variable 
names, well structured) and the occasional comment (usually there was a 
comment at the beginning of public procedures, and there were comments 
next to potentially confusing stuff) was enough for me to understand what 
was going on.  The code I wrote probably needed more comments, since I 
wasn't as good at writing M2 code as they were (and I also had a lot of 
pressure on me to cover a lot of territory, so I didn't go back and 
change variable names to fit their function as much as I should have), 
but I think people understood it anyway.

> >(as opposed to Ada) has a quick debug-compile-test cycle.  Until I
>                                                             ^^^^^^^^
> >graduate (at which point I don't have a clue where I will be working), M2
>  ^^^^^^^^^
>  This explains the bit about non-commented code.
>  You won't work for me with that attitude. Whatever language, be it C, C++
>  Modula-2 or Pascal. It makes no difference.
>  I hate to use the phrase, but I will anyway :-), "in the real world"
>  you have to maintain code as well as write it, and so does everyone
>  else.  No one ever seems to get around to writing real documentation
>  outside the actual program (who said I was perfect :-( not me) and 
>  even when they do it is rare technical documentation that gets anywhere
>  near the level of detail you can reach in code.

THAT IS WHAT I WAS DOING!  I maintained code, 8-12 hours a day for 2 
months.  I found that M2 required less commenting than the equivalent C 
code.  I did not find that it required none.  Sorry for the 
miscommunication.  The last few days of work, I wrote the comment headers 
for my routines.  I comment where it helps.  My point was that M2 is easy 
to read and understand if used correctly.  In M2, you do

  FOR j := 1 TO fooTop DO
    foo := 0;
  END;

In C you do (forgive the exact syntax - I'm a little rusty)

  for (fooPtr=foo;;fooPtr==foo+fooTop)
    fooPtr* = 0;

and you probably could use a comment or two if it were any more complex.  
I guess I'm not fluent enough in C to be able to come up with great 
examples, but the C code that I see has so many thousands of screwball 
constructs that you probably need a comment for every basic operation.  
In well-written M2, you need a comment for every exported procedure and a 
comment for every confusing part.

>  Sorry if this sounds a bit acerbic, but this is one very good yet
>  very simple habit to get into, and the longer you code the more you
>  will appreciate it - even if you are the only one that ever reads
>  your own code. In a year's time it might as well have been a stranger.
> 
>  More and more employers nowadays are asking for samples of code, or
>  even watching you produce code, before they hire you.
>  Clean, well commented code can hardly do you any harm.

I appreciate the advice and will take it into consideration.  However, 
meaningless comments turn an employer off, since they can see that you 
have wasted time commenting something that is obvious.  I like to think I 
have found a good balance.  And the balance for M2 is a lot lighter on 
the comments than C, if you ask me - I will comment a lot more in my C 
code than I will in M2.

============================================================
Douglas Cook, undergraduate in Computer Science at BYU
------------------------------------------------------------
This sentence is false.
============================================================
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads