Subject: Atmel and ZBasic EFI
From: Rotary Engine
Date: 5/2/2010, 2:45 PM
To: AAA Put this in the To box



  Paul writes:
  C is unnecessarily cryptic IMHO and I refuse to waste time
  learning it. PC computers are very powerful these days
  and you should be able to program them in easily understood
  plain language and let them do all the work converting the
  program to bits and bytes. The one thing I did not like
  about the real time Linux approach.

Robin replies:
Totally agree with you there.  Not even a C- program's original
developer can typically pick up a program and modify/debug it a
year after they wrote it.  I strongly suspect that people use C
primarily for job security.

BASIC was around for decades but has its limitations on huge
projects.  but it works fine, I even taught BASIC at the
University level for a couple of years, but then I migrated to
Pascal (because that is what all the colleges switched to for their
introductory programming courses) and I have loved it.
Beauty of Pascal in the good-old-days was that one could pick up cheap
programming help, college kids willing to work for minimum wage
just to earn an little beer-money.  I must have personally written
over a million lines of Pascal thru the years, and some of it is
still being used commercially.  Today there are some Pascal
compilers available for Linux, and I intent to see if I can
get some of my old Pascal written for Windows to compile on my Linux
machine.... in my spare time.

Any programming platform should not require people to redefine
what the majority of technically trained people already know.
C-programmers always seem to use symbols that traditionally are
used for other purposes; For example: they far-too-often use the
underscore-character as part of a variable name.  Well to me
( a guy who in decades past has spent thousands of hours checking
papers of college students) any small horizontal line in a mathematical
expression translates as a "minus-sign". In a similar way, a slash
in an equation means to for a quotient, etc.

So yes ... at this stage of my life, I too avoid C programs at all
cost.

 ---
 I can definitely understand why people don't like C,
 however C is just a tool.  For example, many people would
 consider a vertical mill to be a complicated tool and may
 avoid using them, but to demean its purpose of a vertical
 mill would be counter-productive.  All things have their
 place.

 I have been a C programmer for many years (and a bunch of
 other languages in the past 34 years).  I worked on the
 original OS/2 operating system development in 1988 and 1989,
 and I have written several million lines of C over the years.
 Like many languages, it has a learning curve and it forces
 you to have to grapple with some issues that higher level
 languages handle automatically, like memory allocation and
 address pointers.  They are simply "knobs" on a "vertical
 mill", and once you learn them, you have a hard time wondering
 why it was ever confusing in the first place.  Like many
 tools, once you understand them, you begin to "think" like
 them to solve problems.  For C, that learning curve is
 about a year to become proficient.  Under the same logic,
 it is difficult for a hobbyist to become a journeyman
 machinist -- it takes a while to learn that skill.  The
 same applies to a good pilot -- the harder you work at
 something, the more you get out of it.

 C was written as a replacement for machine language.  If
 you think C is tough, you will find assembly language on
 primitive micro-computer chips a walk in complete darkness.
 I worked with a number of assemblers in my early career and
 can tell you that C was a BLESSING when we stated to use it
 in the early 80's.  I used to remember that a simple divide
 operation on a 6502 chip would take 33 instructions -- in C
 just 1 statement.  It would have been impossible to write
 UNIX, Linux, or OS/2 in BASIC as we needed to have direct
 control over the allocation and use of memory.  When that
 is no longer a requirement, you can begin to consider other
 programming languages.

 C's biggest failing is that it does not have a true "string"
 data type -- all strings are character arrays, and it forces
 the developer to work at that level.  However, there are
 some standard function libraries that make this process
 relatively painless once you get over the shock of having
 to deal with character arrays.  I have written lots of code
 in C that never had to do explicit memory allocation, and when
 I have had to reach deep into the bowels of the operating
 system, C has never disappointed me with what it is capable
 of doing.  It is a wonderful "vertical mill" when you need
 one, but not everyone needs to use a vertical mill to solve
 their problems.

 When I taught computer science at the University of Maryland
 in the late 70's, students would always want to find out
 what the "best" language is.  There is no one "best"
 programming language.  All of the do some things elegantly,
 and at other times require you to go to extraordinary lengths
 to do rudimentary things.  In programming there is a saying
 about modern programming languages that states "it makes
 the hard things really easy, and the really easy things
 more difficult".  It is always about tradeoffs.

 My preferred language now (and for the past 10 years) has
 been Perl.  Perl is widely available, free, and has over
 30,000 free function libraries available (via CPAN, the
 Comprehensive Perl Archive Network) that will allow you
 to do anything you can imagine.  I can write software in
 Perl 3 to 5 times faster than any other programming language,
 and for me, productivity is money in my pocket.  Best of all,
 Perl shares syntax with both C and BASIC, so it is very
 easy to learn Perl.  In Perl, everything is a string (like
 BASIC), so you don't have to get hung up over data types.
 Perl also handles memory allocation and garbage collection
 like BASIC, so you don't have to deal with that issue.
 I have taught people how to use Perl in two days that were
 immediately productive -- that is a phenomenal trick when
 I remember COBOL programmers in the old days taking a year
 to become really proficient in the old mainframe days.

 My advice is always to use the highest level language
 available that will get the job done.  Higher level
 languages, like BASIC, are more productive for common
 tasks.  But when you need to dig deep, sometimes C is
 a much better tool for doing things.  After all, what
 good is a vertical mill when all you want to do is turn
 a screw?  Best,

 Dave Stoddard




-- 
The Rotary Engine NewsLetter. Powered by Linux.
ACRE NL web site. http://www.rotaryeng.net
Youtube key word PaulLamar2
Copyright 1998-2009 All world wide rights reserved.