Slashdot Mirror


Linux Journal Interview With Brian Kernighan

pndiku writes "Linux Journal has an interesting interview with Brian Kernighan where he talks about AWK, AMPL and how he had nothing to do with the creation of C."

15 of 333 comments (clear)

  1. Correct AMPL link by JohnGrahamCumming · · Score: 4, Informative

    The story has a link to ampl.org, the correct link is ampl.com.

    John.

  2. Re:It's official by Lazar+Dobrescu · · Score: 5, Informative
    It is well known that Kernigham had nothing to do with the creation of C. The K&R you are referring too are the authors of the BOOK, "The C Programming Language", that Kernigham wrote with Dennis Ritchie(which is the main inventor of C).

    So, we still have K&R, just as before. Only now, maybe some readers understand better that K&R is not the names of the C inventors, but the name of the people who wrote the book about how to use C ;)

  3. Re:BWK by JohnGrahamCumming · · Score: 4, Informative

    The book you are referring to:

    The Practice of Programming
    Kerningham and Pike
    Addison-Wesley, 1999

    is a classic text and it's very clearly written. The front cover sums up in three words the core philosophy of the entire book:

    Simplicity
    Clarity
    Generality

    It is a delight to read although it uses C/C++ as the example language everywhere and tends, therefore, to be a little C oriented, although there are examples in other languages.

    Much of the material will be familiar to people who've done a CS degree (e.g. trees, O-notation, etc.) but the section on testing is very worthwhile if you are planning to write code that will last a long time.

    John.

  4. Re:If I were Brian... by thogard · · Score: 3, Informative

    The 1st gets was based on a
    while(*buf++=getchar())
    type of loop
    Once the preprocessor got more goodies, and STDIO was cleaned up, it became:
    #define gets(x) fgets(x,BUFSIZ,stdin)
    So in the days when there were only 100 or so Unix sites you could declare strings with
    char buf[BUFSIZ];
    and you couldn't overflow it.

  5. He teaches VB! by Anonymous Coward · · Score: 2, Informative

    Brian K is a really nice guy, it seemed to me. Another gift of the city of Toronto and the University of Toronto to humanity! I heard him talk at UofT a year or two ago. It seems he teaches Visual Basic in his programming course at Princeton. I'm a C nut so that came as a shock to me. Still, I really admire the guy.

  6. Re:Points in article: by DogIsMyCoprocessor · · Score: 4, Informative
    Why'd they interview him?

    Let's see ...

    • He invented Awk, a spiritual godfather to Perl
    • He co-authored The C Programming Language
    • He co-authored The UNIX Programming Environment
    • He co-authored Software Tools, an early manifesto of the "Unix Way" of using small, interoperable tools.

    If you had done as much important work, I think you would be worthy of an interview, too. That's no guarantee that you'd have much to say, of course.

    --

    "And this is my boy, Sherman. Speak, Sherman." "Hello." "Good boy."

  7. Re:FreeBSD on his Mac? by pohl · · Score: 2, Informative

    Can't speak for Mr. Ritchie, of course, but it could be that he was refering to the FreeBSD 4.4 built into MacOS X

    --

    The "cue the foo posts in 3, 2, 1..." posts will commence with no subsequent foo posts in 3, 2, 1...

  8. Re:expressive by nat5an · · Score: 2, Informative

    I'd have to agree. I was taking a grad level course on programming language foundations, and the prof did the famous sieve of erasthones in one line (well two lines, since you have to call the sieve function from somewhere) in Haskell:

    f (h:t) = h : f [ x | x <- t, x 'mod' h /= 0]
    main = f [2..]

    The only reason it's possible is due to Haskell's lazy evaluation, so you can have infinite recursion defining a list, and it's not really a problem, unless you try to grab every member of the infinite list and use its value.

    Well, I was impressed. You all may be jaded.

    --
    Head down, go to sleep to the rhythm of the war drums...
  9. Re:If I were Brian... by BlueWonder · · Score: 2, Informative
    Huh, I consider gets to be a minor (!) snafu compared to the vile mind poison of:
    int foo, *bar;

    Why? It is perfectly possible to write a C program that contains int foo, *bar; and performs correctly for all inputs. The same is not true for a C program that calls gets.

  10. Why Pascal is Not My Favorite Programming Language by NearlyHeadless · · Score: 5, Informative

    Here's an HTML version of Why Pascal is Not My Favorite Programming Language. There's a Postscript version on Kernighan's website

  11. VB and Kernighan's course by Serf · · Score: 4, Informative

    Isn't it odd that I'd recommend to people who want to become programmers to avoid taking Brian Kerningham's class?

    I know people who have taken his classes. I live with one of them (a CS type), and used to live with another (a non-CS type). All of them have nothing but good things to say about Kernighan's classes.

    The class in which he teaches VB is oriented towards non-CS types, and, from what I saw of my former roommate's coursework, I can't imagine a better course to give people who are basically computer illiterate SOME idea of just what goes on inside the magic box, and some familiarity with all the issues surrounding information technology (legal, ethical, etc. ... like what you see on Slashdot every day). It's not just a programming course -- it covers pretty much every aspect of the field of computing and its related subjects, though in somewhat limited depth.

    Complaining about VB's namespace problems in this context is like bitching about giving a toddler a tricycle because he'll never win the Tour de France on anything with three wheels. My former roommate had no problems with his programming assignments that he wouldn't have had in any other language, and, judging from what I've seen of people trying to pick up C and Java for the first time, VB is a far better choice of language for a course that aims to give people a flavor of what computers are all about.

  12. Re:Why Pascal is Not My Favorite Programming Langu by IamTheRealMike · · Score: 1, Informative
    I should note here that the Borland Object Pascal language has dealt with nearly all of the problems presented in the paper, and in many respects is a wonderful language to work in. I know I certainly prefer most parts of it to their C equivalents. The syntax is clear and readable, typecast scoping is clearer, it has powerful built in types (nobody uses arrays of chars for strings and hasn't for years, there is a builtin string type).

    Pascal may be dead, but in Windows-land at any rate its child, Object Pascal lives on. And if you compare how Object Pascal evolved from Pascal to how C++ evolved from C, Pascal wins every time.

    The other neat thing (from one perspective, bad from another) is that Pascal was essentially abandoned to Borland. Lacking the need to standardise it, they added many many useful abilities into the language that make it an ideal Win32 workhorse. Unlike MSVC++, when it would have led to better integration with Windows Borland extended it, for instance IDispatch is integrated into the language seamlessly, so you can do:

    var WordDocument :OleVariant; begin WordDocument := CreateOleObject("Word.Document"); WordDocument.SomeMethod(); end;

    ie in order to support COM instead of messy cludges that make you do things manually support for late bound object methods were added to the language.

    Of course that means you were essentially tied to one companies compiler, but nonetheless that doesn't make the language any less nice.

  13. Re:If I were Brian... by ajs · · Score: 2, Informative

    He was pointing out (rightly so) my lack of malloc. I was assigning to empty space.

  14. Re:FreeBSD on his Mac? by pohl · · Score: 2, Informative

    It's true that there is the Mach kernel involved (here's a simplified cake-layer diagram), but from the context that Ritchie provides ("The way I use them, which is as a casual programmer, it doesn't matter--they are all the same...") none of that is really relevant. The APIs that he expects from a unix are there in the FreeBSD 4.4 code layer. (X11 is there too, by the way). He would have to be using the word "FreeBSD" very pedantically to mean that it's FreeBSD/PPC and not the FreeBSD 4.4 in OSX. It doesn't sound like he's being pedantic in this interview.

    --

    The "cue the foo posts in 3, 2, 1..." posts will commence with no subsequent foo posts in 3, 2, 1...

  15. Re:Why Pascal is Not My Favorite Programming Langu by marhar · · Score: 2, Informative
    I should note here that the Borland Object Pascal language has dealt with nearly all of the problems presented in the paper...

    Pascal's main problem is that nearly every "real world" implementation of Pascal has dealt with the problems presented in the paper, Unfortunately in different and incompatible ways.