72 points · by davidu · 16y ago · 98 comments
They are computer scientists and they are very smart.
But we also like to hire students graduating from college. It's rare for us to find a CS graduate who knows C, let alone one who enjoys writing in C.
Apparently most CS is taught in Java and Python these days, with one or two courses in algorithms or operating systems. There seems to be only a few classes where C is involved.
Is this because teachers don't like teaching in C? Or because students prefer the speed of development of a language like Python or Java? Where are the students who do like C? Where can I find those guys (and girls)?
In fact, I think most of the HN crowd would greatly enjoy the "bomb lab" (http://csapp.cs.cmu.edu/public/1e/labs.html -- you can read the writeup but not get the source). The idea is that you have a binary and have to use gdb and some nice dumping tools to "defuse" a bunch of stages of the program, each with increasing difficulty. It's a fabulous exercise, and really makes students pick up a deep appreciation for stepping through assembly and data structures that are just lying around in memory.
I love the bomb lab exercise! LOVE LOVE LOVE LOVE!
At my university, we split the book into two courses if I'm not mistaken. We moved away from a typical OS book (Albert S., Andy T., Stalling, type of book) to this.
There are side effects though. The MOS, OS Concept, OS Concepts + Internals book have a typical path of teaching OS while this book merged the OS and hardware knowledge.
The bomb and buffer overflow labs are probably the most interesting to the HN community, but the shell project is what I consider the most important project in the course. (We have five projects: bomb, buffer overflow, shell, memory allocator, web server.) Our shell assignment is quite a bit different from the original in that we parse the command line for them (putting the commands and pipelines into appropriate data structures), but they have to do everything else, including pipes and I/O redirection.
Email me if anyone is interested in learning more about how we do our course.
Someone mentioned "Why C when higher-level languages will suffice?" and I thought that's pretty much spot on. In a data structures class, it seems easier not to have to debug cryptic core dumps and segmentation faults too often, especially since the focus is on algorithms. At least, that's the impression I got when speaking with TAs and professors.
Or perhaps there are less systems-level programming enthusiasts nowadays?
I took the class you TA'd, way back when the textbook was still a draft and absolutely loved it! As an EE guy, it was great to be able to get at the bits and bytes and really understand what it meant to be fetching, executing, branching to, jumping to instructions, allocating memory etc. The transition from assembly language to C was natural and I loved/hated every single core dump / segmentation fault that came with it. That class helped tremendously in getting me my first job, but I guess there are plenty of jobs that don't require working knowledge of C.
objdump doesn't give you the pretty "graph view," showing the basic block structure of the code. (In particular, this is really nice for switches and other jump tables.) It doesn't make it trivially easy to see where certain rather important-looking strings are referenced in the code. It doesn't show strings that are being referenced right next to the assembly instruction that references them, like changing
push 0x8049808
to push offset aD ; "%d"
It doesn't let you mark up mov eax, [ebp-0x4]
to mov eax, [ebp-first_number_I_entered]
and have that renaming automatically propagated through the entire function, so that you can easily track accesses to the same variable.In addition, the Hex-Rays decompiler (http://www.hex-rays.com/decompiler.shtml) produces C-like output. I don't have a license for it, but I imagine it would make short work of the bomb lab.
I find C to be an elegant language. But we have so many other things to worry about, like the algorithms, data structures, security, concurrency, etc. If a language can help me with things like memory leaking and segfaults, then of course I'll go with that language over C. I have so many other things to focus on.
We love this stuff.
These are bad schools. I'm really not willing to compromise on this statement.
Is this because teachers don't like teaching in C? Or because students prefer the speed of development of a language like Python or Java? Where are the students who do like C? Where can I find those guys (and girls)?
It's because C and systems are inherently hard and cannot be made... not. When your libraries are limitless your programming exercises can be made as trivial as possible.
I also always choose C if companies let me choose my language during interviews. I can fit the entire C language and its libraries into my brain all at once with no reference manuals.
C++? I don't think I could get everything even if I had the specification and Bjarne himself standing next to me.
These are 95% of schools.
[at UIUC everyone does C++ Data Structures, but CS starts with Java, CE starts with C ]
CompE graduate here, my C education was almost exclusive to microcontrollers. The only other class that focused on C was the operating systems class. Both were fairly low-level in their respective areas.
My local community college (where I started) - De Anza College did that as well. I am sure there are many others, just they may not be the most well known ones.
Not all the top graduates will want to go into systems programming, however. Great chunk of user-level systems programming (e.g., network services, distributed systems) is also being done in languages other than C. I suspect, many no longer view having real-world C experience (as opposed to just knowing it) as imperative for their career.
That said, I am not sure exactly what level of C proficiency are you looking for. I am guessing, strong knowledge of UNIX Systems Programming (IPC, interfacing with the VM, etc...) and BSD sockets? You can only learn this through experience and/or working meticulously, through Richard Stevens' books (I _highly_ recommend the former, even if you don't intend to touch C again). You can't expect to hire people with that knowledge straight out of college, but you can hire students with "good C programming ability and strong understanding of operating systems internals, who are interested in learning systems/network programming" (to put in terms of a job description) i.e., they should know what producer/consume problem is, but they may not always know all about UNIX signals, IPC mechanisms and the Linux VM.
[Edit]
Others have suggested to look for students who took an operating systems course. That's likely the best bet.
But even better would be to find students who hack on open-source projects written in C (e.g. Linux-related efforts) -- that's much more representative of a graduating student's ability to be productive using C. There are a lot of students working on such projects, and it might be worth starting there.
Here is what I remember from college:
./program
Segmentation fault.
Anyone have any suggestions for priming myself to work on a problem without directions and finding a solution as you go along (exploratory programming)? The closest I've come lately is exploring the node.js API and working out a basic web server with auth, cookies, and some MVC structure.
I think the reason for this is that coding in C involves knowing a lot about the insides of a computer (eg. what memory even means, how it is addressed, why allocating a string isn't trivial at the machine level and thus requiring pointers in C, indirection, etc). In other words, there are many prerequisites coming from various other classes.
Another example of the sort of thing I mean, although it doesn't directly apply to C: it's hard to understand space and time complexity (ie. big O) without understanding the complexity of basic steps that requires knowledge of the types of things a CPU can do (eg. that memory is effectively a vector, changing a location in memory is O(1) but inserting data into a vector is far more expensive).
IMHO, there simply isn't time for classes to cover all these prerequisites thoroughly (ie. to a level needed for practical coding in C) before a C class can commence. With something like Java or Python you can ignore the complexities until you have had time to learn them. With C you can't.
Thus, it isn't sensible to teach C in college. At least not as a mandatory thing for a CS graduate. And the moment it isn't mandatory the hard classes will get dropped (I took harder classes because I found them interesting, but that lowered my average compared to what I might have achieved otherwise).
The entire history of CS could be summed up as a move towards higher and higher levels of abstraction. They still expose you to assembly language in good CS programs as sort of a history lesson or to give you a deeper understanding of how it works underneath, but that doesn't mean people actually want to use it.
C is of course nowhere near as far along that path as assembly language, but it's a spectrum and seems to moving in that direction.
His class is why I love C, and you'll find many more like me if you come talk to him.
We went to a super small university (1500 people) and we got to do summer internships and independent study course work with one of our professors writing/modifying embedded wireless drivers in NetBSD. This resulted in a group of students that were more proficient at reading and understanding huge bodies of existing code when compared to students I've TA'd and worked with. This also means we all enjoy working in C (Though honestly most of us prefer C++). We work in jobs like embedded GPS devices. Embedded development for Televisions. Jet engine test software. Embedded signal / sensor processing and integration. It's only now, later on in life, that I realize most of the other people in these fields with us aren't CS guys but rather CE or EE.
tl;dr... Find a student, just 1, that is really into this and then find more students from his university... It's likely the environment / layout of the university's program is largely responsible.
Anyway to echo a bunch of others' comments, EE and CompE's like C. It's great for embedded work. If you find one of us who prefer programming to building stuff, you will be very happy with our understanding of C. On top of which we tend to like to write efficient code (i.e. fast and/or low memory footprint) because we are used to having K's of memory rather than M's or G's.
Also the ECE ("Electrical and Computer Engineering") students here (and probably elsewhere) use a lot of C, so that might be something else to look into, although they're mostly familiar with embedded environments.
Maybe this goes without saying, but no one here (to my knowledge) gets very in-depth into a lot of stuff you might take for granted, for example I haven't met a single student (or many professors) who is familiar with mmap(). There are a lot of really smart students who could probably work out great with a few months of real-world experience and mentoring, but students who could sit down and work on production C code right out of graduation are probably less than 1 in 100.
My school(Tennessee Technological University, graduated a year and a half ago) still requires a semester of C/C++...there were a couple other classes where you needed to know it to interpret the professor's example code, but were allowed to code in other languages if you wanted. I enjoy C, but feel more proficient in other languages as far as getting things done quickly. I guess I just don't use C enough to keep a good grasp of it.
I think students would get more benefit out of being forced to only use C(and assembly?) for the first couple years. It would help them get a better understanding of what the higher-level languages have going on under the hood.
I've been doing web development(Ruby) the past few years. I've played around with extending Ruby with C, but not much.
If you are looking to hire, I might be interested...its about time for a change-up in my life.
I think I would personally have disliked C if college were my first introduction to it, because I associated it with curmudgeonly systems professors and a sort of harder-core-than-thou attitude. But for some odd reason I had already learned C in high school (I think I picked it randomly), and it's a perfectly enjoyable language to use, without the cultural baggage. You can even write things other than schedulers in it!
For production, I wish I had the time or need to optimize code I write, but too often, a server upgrade and reconfiguration is sufficient. At least I depend on some one else writing something great in C (linux, nginx, etc).
Been looking at GoLang and Clang to make the experience a little less painful.
In my university, we did mostly Java(that was the "teaching language" that is used), I only did 3 courses that were primarily taught in C and there were only around 2 more courses that required C.
So what generally happens to most CS students is that they teach you Java in your first year and then any course where they tell you to use whatever language you prefer they choose Java, because thats what they are comfortable with and they have assignment/project deadlines looming, so they don't feel they have time to experiment in a new language.
Your best bet is to hire workterm/Internship students whom you can Train. It might seem like a waste, but its a real cheap way to get an idea of how good the person is, you get them early enough to train some bad habits out of them(if they exist) and evaluate whether they would be a good fit for your company. They also may accomplish something awesome along the way?
I did a 16 month internship before I graduated from University(which was really an 8 month extended to 16 month), most students like myself set up these internships in a way that after the internship they only have 1 semester of classes remaining, so they can ideally work part time with the company they internet with for that final 4 months and hopefully turn their internship into a fulltime Job upon completion.
On the other hand, I know a few people who want to solely work in C because it allows them so much control over how things work, and they're capable of understanding how each and every call they make will basically function. You typically have to look pretty hard for these people specifically, but I find the ones I know are some of the best programmers around. If you're curious about getting in touch with some (I know at least two that I would /highly/ recommend, are looking for summer internships), ping me at mdwrigh2@ncsu.edu
Most of my programming courses are taught in Java. I've brought it up to the faculty though about moving us away from being a Java school. The issue that they presented was that the teachers may not be as familiar with C/C++ as they are with Java. My reasoning behind all of it being that Java is not a good learning language since it adds too much abstraction to get a good idea for what your code is actually doing (i.e. memory).
It doesn't particularly matter though as students who are interested in programming will learn what they want on the side.
For your situation though, I'd avoid people who classify themselves as being a 'Java/Python/C programmer'. There are too many languages and too many problems to limit yourself to merely one or two languages. A good programmer will be familiar with at least a few languages and be able to pick up a new language/framework quickly. Basically it breaks down to simply finding someone who has an interest in programming.
Also, I like C.
I like C, but I haven't invested much time in it because it seems that the job market isn't that good for C programmers. Maybe I'm completely mistaken, but it seems like I couldn't hope to compete with a lot of the guys who have been doing it for 10+ years. I wouldn't even feel comfortable applying for a position that was primarily C.
That said, if someone offered me a job that was primarily C I wouldn't definitely consider it. And I'm sure if they have the patients, I would end up being a good team member. But web development is where my experience lies and it is where I will continue to pursue jobs. As a self taught programmer, the barrier to entry with web development seemed much lower when I was starting out. Again, that could be my own misconception.
These are all obligatory, one can additionally attend optional courses on Prolog, Dylan, Common Lisp and some other I do not recall now.
So yeah, learning C better would take time needed for all these courses and thus would narrow one's view. From my experience, most people do not like to use C for anything other than Algorithms classes, and even then they are more likely to use C + STL than plain C. Those who do can take Advanced Operating Systems classes and tinker with Linux kernel, or Microcontroller Programming.
That said, I personally enjoy using C when it seems to be appropriate. I would much rather write a piece of OS code in C and drop it into a linux distro than using Java to do something that would rarely be used in the real world. I've had problems with C that I wouldn't in a language like python, but if the task is better suited for C, I'd rather work through those problems and learn because of it. My personal opinion of students not learning C because it's hard is that they don't belong in a CS program. If you won't take the time to learn the best tool for the job, you won't do the job right, and no one will have benefitted because of it.
In my side Python projects, if I need speed, I'll write that part in C and compile it to an SO and call it from Python. Nice and painless, easy to port by just compiling 32-bit, 64-bit, dlls and if I care Mac's thing, more enjoyable than pseudo-pythonic libs like pyrex.
I'd suggest looking for computer engineering students if you want people that know C. I'm in the CE program here, but it's almost as much CS as it is CE.
I would look for schools who start their students in C or even C++ right off the bat. I know some people who took intro to programming in Java and would never learn C now, not sure why.
C is used often here in upper divisions for Algorithms, Compilers, and Operating Systems at the very least. I suspect it's used anywhere that theory is deemed very important, because it forces you to understand the theory.
Personally, I don't like coding in it, though I think it's very important to learn in it - it forces you to learn how to do many things at the level of memory management. Learning how to make linked lists in C taught me a lot, for example, and ensuring that my program had no memory leaks also taught me a lot.
On the other hand, this is 2010 and there are programming languages that do memory management for you. Managing memory when you're doing relatively abstract stuff (in most cases) isn't fun OR elegant - it's just tedious. jdietrich talks about this some in another contemporary thread: http://news.ycombinator.com/item?id=1830120
Therefore, I prefer Python - I don't want to program embedded systems.
--
Right now, I'm of the opinion that I ought to be language agnostic. However, I'm also of the opinion that I should know at least two programming languages very well:
I should know one high level language to Get Stuff Done quickly without worrying about tedious stuff like memory management - in these cases, performance is a secondary concern; modern computers are very powerful, and it's much more cost effective to simply write it quickly. Compilers are much better than I am at optimization, and they can do a lot, so why not leave it to them? For this, I've selected Python; I'm working on getting familiar with its many libraries.
I should also know one low-level language for things where performance is critically important, and it's worthwhile to take the extra time to calculate things like that. For this, I'm currently using C, but I plan on switching to Lisp.
With one decent CS school that I am aware of, the University of Maryland used to require (until last semester or so) all CS graduates to take two lower level classes which are taught in C (with some asm). Now it is just one course. I don't know whether or not students enjoyed it, though I think it is unfortunate that they are dropping one of the two courses (actually combining both into one course.)
I think part of why there is this move away from C is some students (rightfully) complain that they may never need to explicitly use it, and Universities figure they can teach the concepts with other languages. I believe that lower level languages should be taught, but I understand why not everyone agrees with me.
I did a bit of lower level stuff for OS/algorithms courses in undergrad but first did C/C++ extensively during my Master's and now my PhD (and Objective C for side projects but that's another story). I love the C/C++ work I do as when I write in C/C++ vs. say python speed is the key issue so I'm doing much more work on algorithm design and parallelization.
For a new grad if they are into the work and a partially seasoned programmer, they'll learn on the job if they don't hack C already.
Otherwise, writing C programs has been called a "historical reenactment" (http://research.swtch.com/2008/03/rotating-hashes.html) and I think for most working programmers this is accurate.
It helps to know some C or C++ if you're using scripting languages like Python or Ruby in order to wrap 3rd party C libraries, but wrapper generators like SWIG will do 99% of the work for you, and what little C code you might have to write by hand doesn't need to be particularly fluent or idiomatic.
As some others have mentioned, I love doing stuff in C. However, I'm also keenly aware of its pitfalls and shortcomings. As such I prefer to do most my stuff in higher level languages like Python and Haskell only dropping to C for speedy data structures (if profiling proofs it necessary) or for convenience when doing low level OS code.
However, I know a lot of my fellow students have an extreme dislike for C and only wanting to program in languages like Java/C#, even languages like Python and Ruby seem under represented.
The students who seem to appreciate systems level code and C seem to be a minority in my university. Which of course means there is more competition to hire these students when it comes to people looking for C developers.
More than enjoying C as a language, you should find people who can identify when it is, or is not, the correct tool for the job. If you hire people solely because they enjoy C, you may find that "when all you have is a hammer, everything looks like a nail".
Putting my money where my mouth is, I have written more C++ in the last month than during the previous decade, because I am doing a lot of node.js work. I am writing code in C++ that speeds up or makes possible the things I want to do in Node. Nothing more.
I personally love C. It's a much smaller language than java, the libraries actually make sense (reading input into a string comes with stdio, as opposed to having to import java.util.Scanner).
I also feel that everything I'm asked to do in java, I can easily do in C with less code. However, this is because I'm more familiar with C than I am with java.
We also learned C# later on in college, and there was always this, "this new thing is nice and shiny but C rocks" feeling among a lot of people in my class.
Also, most of the people (since it was community college) weren't your typical, "I've always wanted to be a computer programmer/scientist/engineer" types.
C is nice, but you feel the datedness of the standard libraries, some basic operations such as string manipulation and what not is more work and verbosity than it should be.
I really like C. Sure it's not as sleek and sexy as Ruby (My uni uses ruby over python), but, it's fast, and it does what you tell it, and nothing more. I actually am really interested in low level systems programming, but unfortunately it's not easy to get experience on that short of being employed in it.
I love coding in C and my first job out of college was C for mobile devices. I have since moved to web programming and rarely use C directly (closest I get is Imagemagick with bindings)
At my univ the introductory programming course is taught using Scheme but there are plenty of course that use C, such as Algorithms and Data Structures and Operating Systems. Hell we even have a course that uses assembly (Computer Architecture). This is all on the undergrad degree.
Also consider looking at physics and aero-astro majors. Lots of embedded or algorithmic work, so I hypothesize lower level languages like C are more common.
As an introductory language, you are taught Java but when you move up to higher level courses such as Algorithms, Data Structures, etc you will us C.
I've also taught myself C++ and I prefer it over C but I have no issue working in any language provided I learn the syntax.
There are a handful of classes taught using other languages (Java, Python) but for the most part we're all C/C++
CS 2110 - Computer Organiz&Program An introduction to basic computer hardware, machine language, assembly language, and C programming.
4.000 Credit Hours 3.000 Lecture hours 3.000 Lab hours
Course Attributes: Tech Elect CS, Engr, &Sciences
C isn't really appropriate for most small projects.