l i n u x - u s e r s - g r o u p - o f - d a v i s
L U G O D
 
Next Meeting:
July 21: Defensive computing: Information security for individuals
Next Installfest:
TBD
Latest News:
Jul. 4: July, August and September: Security, Photography and Programming for Kids
Page last updated:
2002 Feb 24 21:14

The following is an archive of a post made to our 'vox mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox] Why C?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox] Why C?



Options:

   1a. C pros:
      - Portable across many systems.
      - Low-level power at high-level syntax.
      - Few rules to remember -> takes little time to learn everything

   1b. C cons:
      - The low-level nature requires lots of thinking and care.

   2a. C++ pros:
      - C compatibility
      - OOP *or* procedural *or* hybrid programming
      - Options, options, options...

   2b. C++ cons:
      - Too complex, which means:
        - Takes forever to learn the syntax
        - Takes forever to learn to use the features correctly
      - Not very portable [at the moment] if you use advanced features

   3a. PERL pros:
      - Portable, if PERL is available on the system
      - Scripted *or* compiled
      - Options, options, options...
      - Loads of libraries

   3b. PERL cons:
      - Syntax allows too many programming styles
         -> difficult to read others' codes
      - Maintainability is difficult if you're not careful

   4. Python - I don't write in it, but it appears to be a cleaner-syntax
      version of PERL with fewer libraries.

PERL is probably most useful in day-to-day tasks of solving problems. At
least it is for me.  I use C (or sometimes C/C++ hybrid) when I want to
write a clean, reliable program I plan on using for a long time and will
be updating as time goes.  Of course, which one you wanna learn first
depends on what you wanna do.

Something Micah said about C++:

> almost as many of its idioms and concepts get in my way as facilitate

That's absolutely true.  It takes a long time to learn how to use the C++
features properly.  I'm still working on mine (I've been using C/C++ for
about 8 years).  To make things easier, I try to do as much of it in C
syntax, and use C++ features only if it greatly improves the program
reliability or readability, and that policy has worked very well for me.

-Mark

--
Mark K. Kim
http://www.cbreak.org/
PGP key available upon request.



_______________________________________________
vox mailing list
vox@lists.lugod.org
http://lists.lugod.org/mailman/listinfo/vox



LinkedIn
LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
facebook
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
O'Reilly and Associates
For numerous book donations.