Re:Why learn C?
by tosseraccount on Thursday June 28, 2012 @10:14AM
(#4171752)
Well. Think about it. Probably 95% of the instructions executed on your computer were generated by a C compiler or inlined withing a C program. Check out how many of your programs are linked to a standard or special C library. Perl, bash, Python etc. are written in C. Most libraries are written in C.Throw in what's basically C programming in Objective C and C++ and we're closer to 99%
[ Parent
| on HN ]
Re:Why learn C?
by Apocryphon on Thursday June 28, 2012 @12:31PM
(#4172463)
If C++ counts, does Java/C# count as well? If so then we'd definitely hit around 99%
Re:Why learn C?
by tosseraccount on Thursday June 28, 2012 @04:06PM
(#4173638)
No.
C++ is a superset of C.
You can write C and jam it into a C++ program.
This happens often enough in C++ programs.
Java absolutely does count. The Sun JVM was written in C !!! So, yes, every java program is executing instructions generated by a C program.
Some JVMs are actually self-hosting:
A distinguishing characteristic of Jikes RVM is that it is
implemented in the Java™ programming language and is
self-hosted i.e., its Java code runs on itself without
requiring a second virtual machine. Most other virtual
machines for the Java platform are written in native code
(typically, C or C++). A Java implementation provides ease
of portability, and a seamless integration of virtual
machine and application resources such as objects, threads,
and operating-system interfaces.