Home SQL PHP HTML Perl PowerBuilder C/C++ General Solutions Contacts

C

Index
Downloads

C and C++


C versus C++

C has in many ways been superceded by C++, primarily because of the object oriented features of C++. However, C++ compilers will generally compile C code so I've grouped them together. In general I would recommend using the C++ language constructs for any new developments.

C#

C# is a simpler to learn version of C / C++, which is used primarily in .net applications. It's a windows only language and not something I've looked into too much, but from what I've heard it is worth considering for development on windows servers. Given my lack of knowledge in this area I won't comment any further on it at the moment.

What is C / C++?

C has it's roots in BCPL, and a language called B, it was initially developed for Unix systems. There are really 2 forms of C, ANSI C and K&R C, most compilers will compile either syntax but it is probably best to use ANSI C (particularly on non Unix systems).

C++ is similar to C, but also brings the benefits (and pitfalls in the wrong hands) of object orientation. It is one of the most popular languages in use, being used for many different types of systems.

Pros (both C and C++ unless specified)

  • Very fast compiled code
  • Popular development language
  • A large proportion of code developed is cross plaform
  • Full support for object orientation (C++ only)

Cons (both C and C++ unless specified)

  • Can be difficult for beginners to learn
  • Can't test code until compiled
  • Can be difficult to debug without expensive debugging tools (C especially)
  • Fairly slow development time, although tools like Visual C++ make things better
  • Database connectivity can be complicated

Consider using for

  • Command line applications
  • Realtime systems
  • Games
  • Applications which require direct access to the Operating System
  • Any applications where processing speed is of the essence
  • COM objects, when you need an extra bit of performance
This is Code, all contents copyright - © Wayne Jones 2004.