[Color Computer] [coco] Learning MW C

Roger Merchberger zmerch-coco at 30below.com
Wed Aug 16 16:49:16 EDT 2006


Rumor has it that James Diffendaffer may have mentioned these words:
>--- In ColorComputer at yahoogroups.com, "James Diffendaffer"
><jdiffendaffer at ...> wrote:
> >
> > >C on the Coco is not likely to be faster than Basic09. For maximum
>
> > BASIC09 uses a bytecode interpreter.  It's unlikely that it would be
> > even close to C.
>
>Now that I have a minute to retype part of my original post...
>I've been in the 'C' vs compiled BASIC argument many times including
>full BASIC compilers that generate stand alone executables rather than
>byte codes.  C has always won...

That depends on the race!

If the race is getting working code out quickly, Basic09 has always won for 
me over C - My C skills are legendary - legendarily *bad*.

Back when the Pentium 90 was king, my brother-in-law had gotten a P90 
laptop. At the time, about $5K in hardware. He touted that it was the 
fastest laptop on the planet. I told him my 2.4Mhz Tandy 200 (which was in 
the truck at the time) laptop was *much* faster, and challenged him to a 
race, and I even handicapped myself by letting him start before I *got* the 
laptop from said truck. He gave me this look like "I'm gonna eat ya fer 
lunch" and said "You're on."

The race: Boot the computer, start up the word processing application & 
type "Mary had a little lamb."

He hit the power button, I bolted thru the door, grabbed my T200, went back 
inside, hit power, cursored to "Text", typed the sentence, and swung my 
laptop around for him to see. He was still staring at the Win95 boot banner.

My Tandy 200 is *still* the fastest laptop I have - depending on the race. ;-)

[[ And most people don't believe that my CoCo boots to OS-9 from floppy 
faster than my PC boots Win2K from hard drive... ]]

>... and the margin of victory is usually
>pretty substantial if any data processing was involved and the
>application wasn't I/O bound.
>
>One example was a program on the PC that extracted data from the
>mainframe, scanned for errors, sorted it and created a new database on
>the PC.  It took over 20 minutes in the Visual Basic version and under
>5 minutes in C++.  And that was after I optimized the sort in the VB
>program.  It originally took over 12 hours.

Yes, but in *my* personal case:

* The script you need is basically 1-off (most of what I do is 1-off)

* It takes 2 hours to code the program in Basic, but takes 2 weeks in C.

Saving 15 minutes on overall runtime is a "hollow victory." ;-)

I'm not disputing a single thing you said [[ and who knows - you might be 
able to code C quicker than Basic anyway! ]], but sometimes the time 
savings doesn't come in execution speed or CPU cycles.

Laterz,
Roger "Merch" Merchberger

--
Roger "Merch" Merchberger   | "Bugs of a feather flock together."
sysadmin, Iceberg Computers |           Russell Nelson
zmerch at 30below.com          |




More information about the Coco mailing list