"C" Programming Language: Brian Kernighan - Computerphile

Поделиться
HTML-код
  • Опубликовано: 17 авг 2015
  • "C" is one of the most widely used programming languages of all time. Prof Brian Kernighan wrote the book on "C", well, co-wrote it - on a visit to the University of Nottingham we asked him how it came about.
    "Most Difficult Program" - Ackermann Function: • The Most Difficult Pro...
    Computer That Changed Everything - Altair 8800: • Computer That Changed ...
    Factory of Ideas - Working at Bell Labs: • The Factory of Ideas: ...
    More from BWK on other computer languages at: • Computer Science - Bri...
    / computerphile
    / computer_phile
    This video was filmed and edited by Sean Riley.
    Computer Science at the University of Nottingham: bit.ly/nottscomputer
    Computerphile is a sister project to Brady Haran's Numberphile. More at www.bradyharan.com

Комментарии • 985

  • @OSVS_Mike
    @OSVS_Mike 5 месяцев назад +95

    I was lucky enough to be able to work at Bell Labs in the late 80s, right down the hall from Kernighan and Ritchie. I was also learning C at the time and when I spoke to them, they said ANY time you have questions, come in ANY TIME. How amazing to be taught the language by the guys who wrote it! I still have that same book with both their autographs in it.

    • @theencryptedpartition4633
      @theencryptedpartition4633 5 месяцев назад +3

      love it

    • @rouisaek
      @rouisaek 3 месяца назад +1

      What do you think about C now ? Is knowing it let you ez understand High Level Programming Languages

    • @PO-nb8qc
      @PO-nb8qc Месяц назад +1

      @@rouisaekHe mostly likely retired and dont have to think about programming.

    • @rouisaek
      @rouisaek Месяц назад

      @@PO-nb8qc true

  • @Tapecutter59
    @Tapecutter59 7 лет назад +1572

    Thank you Brian from the bottom of my heart. Your legendary 'bible' helped me to escape the mind numbing shift work of a factory floor and has provided me with a comfortable and interesting living for the past 30yrs. The smartest thing I ever did was read and study your book, it is the gold standard of elegant code and still has pride of place on my bookshelf.

    • @franco521
      @franco521 5 лет назад +50

      Can you kindly tell us more about your story? What factory did you have, and how did you come across this book?

    • @mikeosas9838
      @mikeosas9838 4 года назад

      Chrtli

    • @MarechalMaudutor
      @MarechalMaudutor 4 года назад +11

      Please elaborate on your story! We are all very curious

    • @keepercool98
      @keepercool98 4 года назад +1

      NetNavi Leaving a comment on the thread just in case he answers ;)

    • @alonsoACR
      @alonsoACR 3 года назад +2

      interested to hear more!

  • @vladutcornel
    @vladutcornel 8 лет назад +2121

    I started to understand programming from "C for Dummies" by Dan Gookin.
    I didn't even have a PC back then, so I read it like a novel in a school break. When I came back to school, in programming lab, the teacher gave us tasks in exchange for grades. The language was Pascal, not much related to C, but I was able complete every single task in record time, blowing everyone's mind, teacher or colleagues. Someone even thought I was cheating somehow, even though he stood next to me the whole time.
    Before that, I was failing Math and several other, and I could only pass programming tests by cheating.
    That was the one book that changed my life. Now I work as a programmer, with a monthly salary and everything.
    (Sorry for the offtopic comment)

    • @somefuckinguy7107
      @somefuckinguy7107 8 лет назад +127

      No I found that to be an interesting read. Reminds me of myself years ago, but I stopped messing around years ago and I was getting decent at the little things in many languages. I could have been where you are. I am starting to miss messing with computers.

    • @ijusterik5384
      @ijusterik5384 5 лет назад +18

      Inspiring, thanks!

    • @thomashvnmusic
      @thomashvnmusic 5 лет назад +48

      No don't be sorry. That's an amazing story. Thanks for sharing it with us.

    • @MrApplewine
      @MrApplewine 5 лет назад +9

      That's funny. Around the same time I was probably reading C++ for dummies and didn't get very far. I didn't end up doing much programming in my career, but recently I've been looking back at C, which I worked with some in school.

    • @w0ttheh3ll
      @w0ttheh3ll 5 лет назад +13

      C for Dummies was my first programming book - I can highly recommend it for beginners!

  • @pedromonkeypedro
    @pedromonkeypedro 8 лет назад +743

    I almost shed a programmer tear when he held up that copy of K&R. Shame that most people won't truly appreciate the impact this man and his peers has had on modern computing.

    • @FixMyWin
      @FixMyWin 6 лет назад +28

      Pedro Arroyo
      We must remember his contribution every time we produce new software and find a solution to a computing problem 🤝

    • @FixMyWin
      @FixMyWin 6 лет назад +4

      Pedro Arroyo
      We must remember his contribution every time we produce new software and find a solution to a computing problem 🤝

    • @BryanChance
      @BryanChance 5 лет назад +2

      Right on...i totally agree!

    • @tibfulv
      @tibfulv 4 года назад +7

      I learned C from the ANSI version of that book.

    • @bolnyaluo4601
      @bolnyaluo4601 4 года назад +8

      Indeed sir. True heroes do not blow their own trumpets. Ritchie, Thompson and he are the best.

  • @rjrastapopoulos1595
    @rjrastapopoulos1595 Год назад +424

    Maybe it's just me but learning C first makes learning other programming languages a lot easier.

    • @TSWSCI
      @TSWSCI Год назад +32

      They were inspired by C

    • @Moniaar_
      @Moniaar_ 10 месяцев назад +15

      Yes that's right!!, from my experience in engineering college you learn C first, then everything becomes easier as well. Especially c++ and Python, they're a lot easier to understand after knowing C! :) it will be a great journey let's cheer up!!

    • @gere364
      @gere364 8 месяцев назад

      Happens also to me

    • @2002budokan
      @2002budokan 8 месяцев назад +3

      Exactly, C is the best abstraction of the machine.

    • @EdwardChan.999
      @EdwardChan.999 7 месяцев назад +3

      I learned Pascal first, and it made C a lot more digestible

  • @ytgadfly
    @ytgadfly 4 года назад +397

    I used his book many moons ago. It really pissed me off when Dennis Ritchie died around the same time as Steve Jobs and no one seemed to care. Ritchie contributed far more to computing than Jobs ever did. Without Ritchie there would be no C or Unix or spinoffs like Apples OSX

    • @nickschmitt8594
      @nickschmitt8594 3 года назад +78

      Someday we will cherish innovators over industrialists.

    • @jcas
      @jcas 3 года назад +22

      Actually you cannot compare both, since they worked at very different worlds. The fact that they died around the same time doesn’t mean that you have to compare them.

    • @tekashisun585
      @tekashisun585 3 года назад +2

      I’m pretty sure without Steve Jobs, we would not even be watching this video rn

    • @ytgadfly
      @ytgadfly 3 года назад +86

      @@tekashisun585 why? Ive owned computers since 1981 and never owned an apple. They didnt create the internet nor the gui. PARC invented ethernet, the gui, the mouse, laser printing. DARPA created the internet. So why exactly would we have needed apple?

    • @maybona
      @maybona 2 года назад +2

      @@tekashisun585 tell me more

  • @nazavode
    @nazavode 6 лет назад +386

    Those guys at Bell Labs were brilliant. Glad that the foundation of modern computing systems was laid by people like them that valued simplicity over complexity.

    • @1pcfred
      @1pcfred 4 года назад +21

      They always struck me as rather odd birds. I grew up in the town next door to Bell Labs. So we'd see them. I've even worked on the campus. Got to see the guy that walks backwards. There was another guy there that just made paper airplanes all the time. Dennis wasn't working at the Labs by then but I'd see him around and he looked like a space case.

    • @sereysothe.a
      @sereysothe.a 4 года назад +1

      SecularDogma tf are u talking about. there's more technological innovation now more than ever

    • @1pcfred
      @1pcfred 4 года назад +11

      @@sereysothe.a it is a common belief in times of great advancement that many think everything has been discovered. Happened the turn of the 20th century too. You know, the Age of Steam. The Titanic sinking brought a lot of folks back to reality. Turns out we weren't quite the masters of time and space that we thought we were.

    • @arnoldhau1
      @arnoldhau1 4 года назад +7

      Well those who valued complexity and "feature completeness" more did also try. So I guess it is not an accedent that it was those who valued simplicity layed the base, the other approaches simply failed (and had to fail).

  • @jasondoe2596
    @jasondoe2596 8 лет назад +622

    Wow, the legend himself!
    Along with acclaimed hackers Ken Thompson, Dennis Ritchie and Robert Pike, Prof. Brian Kernighan pretty much shaped the modern world of computing.
    The Unix/C duet is still the archetype and the measuring stick for modern operating systems and programming languages. Conciseness, control, exceptional engineering that didn't ever get old - and the ability to shoot yourself in the foot if you want so. Good stuff!
    And the K&R C book is truly praise-worthy. Timeless and very, very elegant.

    • @alexandrugheorghe5610
      @alexandrugheorghe5610 8 лет назад +34

      Jason Doe Great memories I have with that book, trying to bit shift values in the bus people were looking really strange at me while I was holding the book and was scribbling in binary like a crazy person on the notebook... Don't think they even thought it's about Computer Science.
      Just wanted to share my story since I love your comment.

    • @jasondoe2596
      @jasondoe2596 8 лет назад +1

      Josh Barrett I agree that Plan 9 seems incredibly cool! (...not to mention its beyond-awesome mascot bunny xD )
      Many features of Linux (my everyday OS) such as the /proc kernel interface do indeed trace their ancestry to Plan 9 design ideas. Sadly I haven't ever used Plan 9 itself - I should probably fix that omission!

    • @alexandrugheorghe5610
      @alexandrugheorghe5610 8 лет назад

      Josh Barrett
      yes: better have some more weekends; it took me 1 week to get the networking going in VirtualBox, even posted to the mailing list and the headache is well known that from update to update some functionalities are broken with various drivers from virtualization technologies but all in all, it's a great approach
      I also found interesting built-in UTF-8 support... was weird to see strange characters on my screen when I mistakenly pressed some keys

    • @THB192
      @THB192 8 лет назад +5

      Alexandru Gheorghe Yeah, the networking support in VBox is pretty terrible in the official release. Some fan supported ones have better support. Kind of ironic for a distributed system. Fun fact: UTF-8 was invented for plan 9 by Ken Thompson, who described it to Rob Pike using the back of a paper napkin. Some more of the history is actually in a video on this channel.

    • @TechnocraticBushman
      @TechnocraticBushman 8 лет назад +8

      +Alexandru Gheorghe About bit banging and exotic architectures, I am currently doing a little 8 bit microcontroller driven home project. You can't even begin to appreciate what C is until you see just how much you can squeeze out of it. You're so close to the bare metal that you can visualize the flip-flops of the register setting while you type _DDRD &= ~(1

  • @MrPoutsesMple
    @MrPoutsesMple 7 лет назад +243

    I never thought I'd have the privilege to watch B.Kernighan talking on C.
    For this, thank you Computerphile and please keep it up !!!

  • @turdwarbler
    @turdwarbler 3 года назад +99

    I learnt C in 1981 and I have used it for the last 40 years. It is just a fantastic language, much copied but never bettered. I now use C++, but mainly as a C with classes style language. I have always written either device drivers, or low latency high frequency trading systems, and C is the perfect language for these tasks. I love it and thank my boss Peter Madams for teaching me it all those years ago. It will see me into retirement I think.

    • @abednego8304
      @abednego8304 2 года назад +1

      Wow how I wish i could get to know you sir. I have a project am on

    • @honkhonk8009
      @honkhonk8009 9 месяцев назад

      Damn. Peter Madams sounds like a chill guy

  • @ThaRSGeek
    @ThaRSGeek 8 лет назад +661

    "Ritchie was under the radar. His name was not a household name at all, but... if you had a microscope and could look in a computer, you'd see his work everywhere inside."

    • @PureGamingTV
      @PureGamingTV 8 лет назад +14

      A Cat -- Paul E. Curuzzi (IIRC)

    • @baruchben-david4196
      @baruchben-david4196 6 лет назад +3

      A Cat He was well-known back in the 1980's, in the computer lab at my school...

    • @meteor8076
      @meteor8076 6 лет назад +15

      Dennis Ritchie is a LEGEND !

    • @1pcfred
      @1pcfred 4 года назад +6

      If I went to the grocery store I could run into Dennis Ritchie occasionally. It was right down the street from the office building where he worked. He was a pretty nondescript kind of a guy that no one paid any attention to. He always struck me as looking a bit preoccupied though.

    • @koj2698
      @koj2698 3 года назад

      @@1pcfred where did you live?

  • @marcnorth
    @marcnorth 8 лет назад +91

    That book was, to me 25 years ago, the absolute keystone of my programming education, and Prof. Kernighan is a delight to listen to and learn from.

  • @pandaDotDragon
    @pandaDotDragon 7 лет назад +38

    K&R C: the best technical book I've ever read. So well written.
    A course on the language plus an introduction to algorithmic plus explanations how the stdlib is implemented (page after page we can follow the evolution of the implementation). A real gem.

  • @hrnekbezucha
    @hrnekbezucha 8 лет назад +349

    So grateful that Computerphile came to existence. Thank you, Numberphile ^^

  • @pspicer777
    @pspicer777 4 года назад +13

    I feel so sorry for the young CS folks today. They missed out on some real magical times. I started University just after it was published. Both he and Richie, amongst others set the stage for all we have now.

  • @WickedMuis
    @WickedMuis 8 лет назад +677

    4:18 "...but is it a bit like making a sharper tool and using that sharper tool to make a sharper tool?"
    C# ..?

    • @randomaccessbrains
      @randomaccessbrains 8 лет назад +277

      Wicked Mouse Kids these days be like C hashtag

    • @iluvDNA100
      @iluvDNA100 8 лет назад +52

      Ramses De Vuyst *C Octothorpe.

    • @32lizOtuseM
      @32lizOtuseM 8 лет назад +20

      Ramses De Vuyst It is not a hashtag. It is just C hash. If the hash was used to tag something then it would be a 'hashtag'.

    • @WickedMuis
      @WickedMuis 8 лет назад +32

      32lizOtuseM It's actually "C Sharp" B)

    • @32lizOtuseM
      @32lizOtuseM 8 лет назад +12

      Wicked Mouse Yes, but Ramses De Vuyst was joking and he was aware that 'C hashtag' was not the actual name. I was talking more about the individual name of the symbol. Some people call it 'number sign' and 'pound sign' too.

  • @negsurbansports1234
    @negsurbansports1234 8 лет назад +15

    I love how you can see the passion as he talks. It's so infectious and makes me wanna learn C!

  • @moonbeam7434
    @moonbeam7434 8 лет назад +176

    Started programming when I was 28, and now I'm finishing my masters degree in natural language processing. Nowadays I mainly use Python, JavaScript and Lisp/Clojure. When I saw this video I realised I really miss programming in C. This book, and The Structure and Interpretation of Computer Programs by Abelson, Sussman and Sussman are the two most important books I have read. The third is Catcher in the Rye.

    • @ibrahimeldesokii7883
      @ibrahimeldesokii7883 8 лет назад +1

      can you help me , please in c++

    • @scowell
      @scowell 8 лет назад +41

      class Knowledge; // fwd decl'n
      class HardWork; // " "
      class Help {
      friend Knowledge *books (const Library, const Internet);
      friend HardWork *woodShed (const Study, const Time);
      }

    • @SeroX
      @SeroX 7 лет назад +1

      i just bought this book by K&R, but i just noticed after ordering that its 1st edition. do you think i could still get use out of the 1st edition over the 2nd?

    • @zzHackedTutorialzz
      @zzHackedTutorialzz 7 лет назад +1

      @scowell You might wanna take some of those parameters in by reference.

    • @3nertia
      @3nertia 7 лет назад

      "Natural language processing"?

  • @johnvonhorn2942
    @johnvonhorn2942 8 лет назад +641

    I feel the need, the need for cpeed.

    • @pspicer777
      @pspicer777 4 года назад +2

      John von Horn JvH, I am gonna so steal this. Brilliant!! Merry Christmas and Happy New Year to you and yours.

    • @holdenrodrigo5067
      @holdenrodrigo5067 4 года назад +4

      pspicer777e

    • @Oodelally
      @Oodelally 3 года назад +1

      speedf()

  • @w0ttheh3ll
    @w0ttheh3ll 5 лет назад +5

    Currently reading the second edition.
    K&R do an amazing job of thoroughly covering every important aspect of the language in an incredibly short and very readable book.

  • @johnny_eth
    @johnny_eth 7 лет назад +11

    These videos with Brian Kernighan are awesome. Like watching a documentary.

  • @tedspradley809
    @tedspradley809 2 года назад +4

    A truly excellent book. In 1978 I was an assembler programmer, working on minis and micros like PDP11 and Z80. A colleague showed me this book and let me borrow it. I only read the introduction and the appendix and gave it back quickly because he hadn't read it himself yet. Ten years later I finally got my hands on a C compiler, and the language just came naturally to me, because of that appendix.

  • @Benjuthula
    @Benjuthula 8 лет назад

    Kernighan and Ritchie has been an invaluable resource throughout my career, it's a great book and a delight to have finally 'met' the author. Thanks for posting.

  • @pornpori
    @pornpori 8 лет назад +17

    He is truly one of the men who helped shape today's technology.
    Thanks for bringing him.

  • @wickeddubz
    @wickeddubz 4 года назад +9

    He is so inspiring! He is full of life ,wisdom, enthusiasm and great ideas. And he is great storyteller

  • @NeilRieck
    @NeilRieck 8 лет назад +19

    The original K&R manual has a RED cover and is stapled rather than bound (and yet also has 3-drilled holes). IMHO this language has literally changed the world. K&R were originally thinking about how to get their new OS from an 18-bit PDP-7 to a 16-bit PDP-11 which had been ordered by was many months late. What they came up with (portable language and OS) enabled today's Open-Source movement.

  • @imqqmi
    @imqqmi 3 года назад

    When I got the book in the early '90 I've read it cover to cover multiple times to wrap my head around pointers. I still use c in microcontrollers to this day and what I learned back then is still very useful. Thank you Kernighan and Ritchie for such a great foundational work!

  • @kylebrown2903
    @kylebrown2903 8 лет назад

    I am constantly astounded by the legends you keep bringing in to talk.

  • @buxeessingh2571
    @buxeessingh2571 5 лет назад +9

    "C is a language that trusts that the programmers know what they are doing. Of course, as a current C user, you know that means that you can get into weirder trouble faster in C than you can with almost any other language in widespread use."
    --- UNIX Review
    After all these years, C is still my all-time favourite programming language. Java, C#, Python, JavaScript, etc. are fine and I use them all, but C has an elegance that is hard to describe.

  • @papasmurf9146
    @papasmurf9146 2 года назад +6

    I've always consider The C Programming Language to be the pinnacle of how a book on a computer language should be written. It is concise. It presents the idea and syntax. It presents exercises to facilitate understanding. Entirely too many other technical books are written by frustrated novelists that are obviously paid by the pound of the finished product. With The C Programming Language you don't have to wade through unnecessary cruft trying to figure out what the important parts are. Only the important part is presented. Thank you Mr. Kernighan!

  • @DriscollJeff
    @DriscollJeff Год назад

    I really enjoy listening to Brian and his coverage of the past and his and others contributions to what many people take for granted today.

  • @thawtar682
    @thawtar682 7 лет назад +2

    This is my first time watching anything from this channel and now it got a new subscriber. Thank you very much for this great video with a legend!!!

  • @thermalCat
    @thermalCat 5 лет назад +46

    K&R is the gold standard by which other software books are measured - clear, concise & coherent.

  • @jez9999
    @jez9999 8 лет назад +5

    I have that book! One of the first I read on programming. Read it from cover to cover - lots of info packed in, easy to understand, not too short, not too long. Highly recommended.

  • @hixamjocular6591
    @hixamjocular6591 5 лет назад

    Thanks for , taping this session it's very interesting to watch this interview with Mr.Brian Kernighan !

  • @leadrevolver
    @leadrevolver 8 лет назад

    It's great to see Brian, It's so cool you got him for a video.

  • @jamesmurphy5499
    @jamesmurphy5499 8 лет назад +24

    Why is Dennis Ritchie's death so mysterious though? No details were disclosed regarding his demise. He's such a legend I just wanna know everything about the guy!

  • @marcduperron6062
    @marcduperron6062 8 лет назад +29

    I have read the first and second editions of the C Programming Language books.
    C is my favorite programming language. In fact, I call it a powerful assembler language.

    • @MaleSoCal
      @MaleSoCal 2 года назад +2

      Settle down; that is a stretch. Do much assembly work?

  • @ddostesting
    @ddostesting 8 лет назад +1

    I remember a lecture with Brian when I was in my 20's. He was very influential in my career. Fantastic guy!

  • @peteryang4422
    @peteryang4422 6 месяцев назад

    By learning and reading this C language book plus Richard Steven's Unix Tcp/ip books, i supported myself and feed my family for many years.
    Thank you from the bottom of my heart.

  • @andrew_owens7680
    @andrew_owens7680 5 лет назад +41

    It's as though I'm an astronomer and they are having an interview with Galileo! This is our Galileo.

    • @1pcfred
      @1pcfred 4 года назад +1

      Astronomy night was a thing at the Labs. They'd get out on the front lawn with their telescopes and stare into the night sky. That and they had a model airplane club too.

  • @jabelltulsa
    @jabelltulsa 8 лет назад +345

    "C" is awesome, and all of these dudes are superstars. Keep your Kardashians, your talking heads, and political hand puppets, and gimme Dennis Ritchie and Brian K. RIP Dennis.

    • @stonent
      @stonent 8 лет назад +11

      +Jason Bell C begat so many other languages. C++, Objective-C, Java, C#, JavaScript. All of them at a very basic level can run the most rudimentary C commands since there was no need to reinvent the wheel. int x = 3; Then you get to things like PHP and PowerShell, neither are as close to C as the previous languages I mentioned, but they start looking like C when it makes logical sense such as blocks of code that have to run together after a decision is made or in a loop.

    • @dannygjk
      @dannygjk 8 лет назад +6

      +stonent Java...(running to the bathroom to throw up...)

    • @stonent
      @stonent 8 лет назад +11

      The main thing I dislike about Java is the 80 billion versions of it that are never the right one for what you're trying to do. At least with C# you're covered with just have a recent .NET framework.

    • @rl1491
      @rl1491 6 лет назад

      nice photo :D

    • @kylesmiles5523
      @kylesmiles5523 5 лет назад +10

      keep talking heads out of this!!

  • @OldieBugger
    @OldieBugger 7 лет назад +1

    I loved that book, and C afterwards. I read it like a novel. One of the best novels I've ever read. Thank you, mr. Kernighan.

  • @lundissimo
    @lundissimo 2 года назад

    So great to see this legendary pioneer speaking about the early days. After working with PDP-11 assembler language on CMX video editing machines, I got that white book in 1978 and found deliverance from those infernal 3-letter commands. Thank you Brian!

  • @PeterWalkerHP16c
    @PeterWalkerHP16c 8 лет назад +37

    ahhh the early '80s
    Borland Turbo C ... sigh. Simple days with simple hardware.
    Although I did like the Turbo Pascal also. (Actually I *really* liked it)

    • @nosuchthing8
      @nosuchthing8 6 лет назад +3

      Try lazarus. It's great.

    • @markgrennan5855
      @markgrennan5855 5 лет назад

      Yes 16c

    • @baruchben-david4196
      @baruchben-david4196 5 лет назад +1

      Turbo C. I have many great memories of the time I was using it. I learned a lot, and had a lot of fun doing it.

  • @justahker3988
    @justahker3988 8 лет назад +39

    Brian's thoughts on C++, especially the container classes?

  • @artukikemty
    @artukikemty 3 года назад +2

    A living legend Brian Kernighan, I bought his book some years ago, one fo the last copies in spanish and that's how I learned C. I had previously learned Pascal, but no other language has influenced so much modern languages such as C, then C++ and then the rest, such as Java, Python but any way for every one interested on learning how things work from the basics and get a solid foundation for learning higher level language C is the choice. If I could only have time to learn one language, I would go for C. Thanks Brian, your work has inspired many of us.

  • @boudreauxbroletariat3959
    @boudreauxbroletariat3959 3 года назад +2

    Brian kernighan has always been my favourite of those og unix guys. when he explains it, i feel like i don't have to be an expert to understand what he's saying. he's a fantastic communicator and ambassador on behalf of the computer sciences.

  • @rebeccastone6557
    @rebeccastone6557 5 лет назад +4

    I have had two versions of this book in my life and carried them around for many years.. it's just the basics of my life in It. :)

  • @THB192
    @THB192 8 лет назад +31

    I like how Brian talks about computer history without going full-on cat -v, if you catch my drift.

    • @dannygjk
      @dannygjk 8 лет назад +4

      +Josh Barrett lol I love you're using a glider from Conway's life "game" for your avatar. I wrote my own programs that simulated that :)

  • @diegosolis9681
    @diegosolis9681 4 года назад

    What most impresess me is the level of humblesness that this guys show. Both have +100 years of experience together adn yet they are so humble and simple. Masters of their craft.

  • @mr16ga
    @mr16ga 3 года назад +2

    One of the gods of computer programming. All pay homage now. I am so glad he has left us with interviews.

  • @gnagyusa
    @gnagyusa 8 лет назад +34

    C still rocks. It's the best programming language, ever. C99 has everything you need for building an elegant and efficient object-oriented framework, without the huge baggage of C++, or other OO languages.

    • @godfreypoon5148
      @godfreypoon5148 8 лет назад +19

      +lnpilot Lots of kids these days saying things like "Hurr durr, why would I ever write in C?".
      Yes, you go over there and play with your snake language. The grown ups have important software engineering to do, for projects that Actually Matter.

    • @gnagyusa
      @gnagyusa 8 лет назад +7

      Godfrey Poon Perfectly said!
      :)
      Very few things (if any) that matter are written in one of these "toy languages".
      Real men code on C!
      :)
      I've written a large application (3d modeling 3D animation, rendering / CAD /CAM) software in C and it's orders of magnitude faster and more efficient than the competitors...

    • @nadirjofas3140
      @nadirjofas3140 8 лет назад

      +Godfrey Poon What kids are you talking of?

    • @ThorX89
      @ThorX89 7 лет назад +19

      I feel like apart from shells (and possibly frontent web cause you don't get much of a choice there) , anything higher level than C was a huge waste of my time. C actually simplifies a lot of stuff. C++ complicates and for what's mostly FUD. Like those pointers and resource ownership are so scary, and you need several huge, compile-time-hogging template libraries to protect yourself from all that. They aren't, and you don't. And without the baggage that is C++ standard libs, C compiles so fast a compile+run cycle is often much faster than a run cycle of a modern scripting language.

    • @gnagyusa
      @gnagyusa 7 лет назад +2

      +ThorX89 Amen to that. Perfectly said!

  • @VaibhavSharma4
    @VaibhavSharma4 8 лет назад +7

    Till this date this is the first book they recommend to students when starting College, truly a legend

    • @tissuepaper9962
      @tissuepaper9962 3 года назад

      This book was a required text in one of my classes just last semester and I'm not even in CS.

  • @masheldon
    @masheldon 7 месяцев назад

    Thank you for this video! I have a copy of that original version of the book. The front cover has come detached, but I proudly keep it on my shelf. Clarity and concision. Thank you, Brian! (And I've been using your Understanding the Digital World in another class recently, so thank you for that, too!)

  • @yohannon3405
    @yohannon3405 8 лет назад

    I love this, I love Brian. Love this video, great job Computerphile!! :)

  • @crash1013
    @crash1013 5 лет назад +3

    When I learned the C Programming Language back in the 80's, this is the guy who taught me. A great book.

  • @TheNefari
    @TheNefari 8 лет назад +41

    ***** the bootstrapping part made me curious please more on that :D

    • @megamef
      @megamef 8 лет назад

      TheNefari I think computerphile covered it in an earlier video but i've never really understood it

    • @ModusTrollens91
      @ModusTrollens91 8 лет назад +19

      The idea is that there is a way to compile C code into assembly code. They could try to write that algorithm in assembly code, but the algorithm is so complicated that it is very difficult to write in assembly directly. So instead they write the algorithm in C. Once they have that down, they then compile that program to assembly by hand using the same compiler algorithm. And now they have a compiler written in assembly which can convert future C code into assembly.
      They could have also written the compiler in B or w/e other high level language and use an already existing compiler for that to generate the assembly code.

    • @anthonyz3400
      @anthonyz3400 8 лет назад

      Alex Quintero
      >So instead they write the algorithm in C. Once they have that down, they
      then compile that program to assembly by hand using the same compiler
      algorithm.
      Wait, could you elaborate a bit? So you're saying cc must be first manually translated to assembly using cc itself, which then carries its own. I don't understand how it's easier to first write the compiler in C.

    • @Roxor128
      @Roxor128 8 лет назад +16

      TheNefari
      1. Write your nice compiler in the language you're developing.
      2. Write a quick and dirty compiler in some other language.
      3. Use the quick and dirty compiler to compile the nice one.
      4. Use the nice compiler from now on.
      The point in the development of a programming language where you can use the language to write a compiler for itself is called the break-even point. This is, obviously, not applicable for interpreted languages.

    • @MrSlowestD16
      @MrSlowestD16 8 лет назад +7

      Tamaki Imouto If you have an algorithm, say a sorting routine, you write it once in C, that C code is portable, it's just text. It can be compiled with a compiler for X86, and will work on X86 arch, it can be compiled with a compiler for MIPS, and run on MIPS, it can be compiled with a compiler for ARM, and run on ARM, etc. The reason to use C is that the inputs are common (you write C), but the output is machine specific (binary, made for that processor).
      It's MUCH easier to write an algorithm (any algorithm) in C than it is to write it directly in assembly (assembly can be thought of as human readable machine code - there's much more to it of course, but it's an easy and efficient way to think of it), so obviously people were prefer to write algorithms in C.
      So there's an obvious advantage for writing an algorithm in a higher level language such as C, the algorithm will be less error prone and take less time to debug and write. The disadvantage to using a higher level language is that most run on top of an interpreter, they aren't direct binary code which executes in HW...the interpreter takes time to run, which inherently makes higher level languages slow. C was one of the first high level languages to compile directly to binary (binary and assembly are specific to a processor architecture).
      I guess you can simplify the entire issue as follows:
      - High level languages write quickly (easy to debug, easy to write) and portable, but are also slow
      - Assembly is not portable (x86 assembly will not work on a MIPS processor), is VERY slow to write, but it's very quick once it's written.
      So with C you have the writing efficiency of a high level language along with the portability but since it compiles directly to binary it has the efficiency of a low level language.
      Does that answer your question?

  • @OldDogNewTrick
    @OldDogNewTrick 7 лет назад

    Pleased to meet you here. I owned this book once, and may still have it hidden away somewhere. I also had a BCPL manual once. I remember a co-worker that used to build stuff with the 'B' language on a Honeywell time-sharing environment. At this time I was coding mostly in assembly language (Honeywell Easycoder) and a bit of COBOL. Pretty well taught myself 'C' from your book, and also C++ and later C#. Thanks for your major contribution.

  • @keithroten4722
    @keithroten4722 8 лет назад

    I'd like to pay special thanks to Prof Kernighan. I learned C from a 2nd edition of his 1st book. Programming language manuals were and still sometimes are confusing or organized as simply as alphabetically by each instruction name. His book was fun to read and easy to follow. I had a fairly good understanding of and was able to begin using C after just one fairly quick read of his book. Around the office we affectionately called it the C bible.

  • @jeffirwin7862
    @jeffirwin7862 8 лет назад +41

    Sean and Brady: congrats on getting such a huge Comp Sci celebrity to interview in this fantastic video.
    "The C Compiler is written in C." -- Brian Kernighan
    Then what compiled the first compiler? How do you build a crane without using an even larger crane? The process of bootstrapping still blows my mind.

    • @antoniopoianella9636
      @antoniopoianella9636 5 лет назад +40

      You make a simplified C compiler in asm, use the simplified C language to make a full-featured C compiler, then use that one to compile itself

    • @mohamedfouad2304
      @mohamedfouad2304 5 лет назад +5

      Trusting trust

    • @antoniopoianella9636
      @antoniopoianella9636 5 лет назад +2

      @DFS54 I'm sure you could do that yourself rather quickly, interpreters are much easier than compilers.

    • @douggwyn9656
      @douggwyn9656 5 лет назад +4

      A more efficient approach is to use any existing implementation of a C compiler to "cross-compile", producing binary code for a specific platform other than the one running the compiler (aka the "development platform"). Then while debugging the cross-compiler (using mostly the cross-compiler's own source code) one just needs a way to copy and execute the binary code. This can even be done before the new platform hardware exists, using a simulation of the proposed new computer architecture that runs on the development platform.

    • @JimInTally
      @JimInTally 5 лет назад

      @@antoniopoianella9636 So, in the beginning you have to use assembly language?

  • @guitmz
    @guitmz 5 лет назад +8

    How can someone dislike a video where Brian talks? How can one disagree with one of the only guys who were actually there? Ffs

  • @andremoreau7057
    @andremoreau7057 2 года назад

    I learned C from that very same book. Great book. Clear, to the point, and no useless blabla. I learned very quickly. Thank you.

  • @theena
    @theena 2 года назад +1

    Reading it now. To a beginner such as myself, it can be demanding. But take the time, and it will reward you. Thank you, Professor.

  • @MrDavibu
    @MrDavibu 8 лет назад +84

    That's awesome!The inventor of "Hello world!" D:

    • @user-dl9cw8mi3f
      @user-dl9cw8mi3f 7 лет назад +15

      MrDavibu Also the inventor of C, UNIX and a bunch of other stuff.

    • @chukybaby
      @chukybaby 5 лет назад +11

      The inventor "hello, world
      ". Just nitpicking

    • @armincal9834
      @armincal9834 4 года назад +1

      #include
      int main(void)
      {
      char word[11] = {'h' , 'e' ,'l' ,'l' ,'o' ,'\t' ,'w' , 'o' ,'r' ,'l' , 'd'};
      for(int i = 0 ; i < 12 ; i++)
      {
      printf("%c " , word[i]);
      }
      return 0;
      }
      Im not nit picking at all

    • @obidahasdia4095
      @obidahasdia4095 4 года назад +2

      @@armincal9834 you dont need a for loop to print a string you do that in arrays

    • @arminharper510
      @arminharper510 4 года назад

      @@obidahasdia4095 in C, strings are arrays of chars :) you can of cours use printf("%s", arr) but even when you do that, that's what happens under the hood :)

  • @fxcoder7983
    @fxcoder7983 5 лет назад +3

    This was the only programming language book that I've read from start to finish. It was technical, but so easy to read. BTW noone should ever have to read a programming language book from start to finish, just use the index pages to find what you want :)

  • @gnuPirate
    @gnuPirate 2 года назад

    Oh man.... such an amazing, cool, and insightful interview. A little chunk of history.

  • @AllThatInterestingStuff
    @AllThatInterestingStuff 5 лет назад +1

    Kernighan & Richie's book on C programming was my first ever book that I bought for myself around the age of 10... Best programming book ever.

  • @herrfriberger5
    @herrfriberger5 6 лет назад +4

    The language that messed up the equal sign for decades to come. It started off with Ken Thompsons ugly hack on the elegant BCPL language (which he called B, later C).
    That's a pretty nice book though. I read it in the 1980s.

  • @VijayKanta
    @VijayKanta 7 лет назад +4

    The 70s probably is the best age, and Thompson's smirk tells it all.

    • @ddmozz
      @ddmozz 5 лет назад +1

      The late 60s was the best age. So many things going on, including moon landings and the first message ever sent on the internet (1969) and, of course, the development of C language.

  • @drwisdom1
    @drwisdom1 4 года назад

    I bought the 1st edition of K&R in 1982. It is the most influential book I have ever read. I got the opportunity to have Prof. Kernighan sign my copy in the late 1980s. I haven't seen him since then, until this video.

  • @EpicAOEsRealm
    @EpicAOEsRealm 4 года назад

    By far my favorite programming book.Absolutely incredible work! :D

  • @Yuri-bt4wl
    @Yuri-bt4wl 5 лет назад +7

    APPENDIX A: *C REFERENCE MANUAL*
    I have no words to express how incredibly useful this is!
    I recomend anyone who reads this book to start from this APPENDIX A, or to jump to it after the introduction.

  • @js32096
    @js32096 7 лет назад +19

    I guess those extra bits aren't really "COMING SOON"

  • @LiamMayfair
    @LiamMayfair 5 лет назад +1

    What a legend, just like his peers Thompson and Ritchie. We owe so much to them. I'm reading K&R at the moment and it's fantastically written. Concise, clear and useful. 100% recommended for anyone seriously interested in C. Can't get any better than hearing about it straight from the horse's mouth!

  • @randaldavis8976
    @randaldavis8976 7 лет назад

    Thank You, Mr Kernighan. I used to find copies of the C Manual shipped with some of the computer I was using at work. I used them as bait for others to steal, so they didn't run off with my copy that had my index tabs & notes in it. Never noticed the book came out late 70's, thought it was earlier. I got my first copy about 1980. I learned to operate a unix box so I could play rogue.

  • @TheBluMeeny
    @TheBluMeeny 8 лет назад +9

    OMG Brailsford with the pen made me laugh so hard!

  • @TheNBKiller
    @TheNBKiller 8 лет назад +12

    I really can't wait to start studying this type of stuff in college

    • @michaelmamic4682
      @michaelmamic4682 7 лет назад +49

      Don't wait. Start now.

    • @0x8080
      @0x8080 7 лет назад +17

      Seriously, there's no reason to wait at all. Go for it!

    • @iTacc01
      @iTacc01 7 лет назад +7

      English does not seem like one of those.

    • @rudyeilabouni
      @rudyeilabouni 7 лет назад +2

      All you'd do in college is learn math. Haha so start learning this stuff on your own. It will help you!

    • @avro549B
      @avro549B 7 лет назад +3

      They'll probably try to force feed you Java. Don't rely on being taught a language; it's usually done badly, and slowed down for the people who'll never get it anyway. Computer programming is for people who can teach themselves.

  • @LukasLevickas
    @LukasLevickas 8 лет назад

    I want the extra bits part NOW! :D Thanks for content!

  • @JamesHunterRoss
    @JamesHunterRoss 7 месяцев назад +2

    This is one of the BEST books I ever read; it changed my life. I decided to learn C because the book was so thin, and because Unix and C both made sense. The other languages at that time (Fortran, Cobol, RPG, etc.) seemed weird. I developed software for almost 40 years, and this book was the beginning. The books is clear, concise, and inspirational.

  • @scottycatman
    @scottycatman 8 лет назад +127

    That book is literally two feet from me!

    • @elfbier8935
      @elfbier8935 8 лет назад +2

      Scotty Catman Same here. They must have sold millions of it. :)

    • @angeldude101
      @angeldude101 8 лет назад +1

      Scotty Catman 1 foot, take that.
      Edit: 1978 edition

    • @linusbrendel
      @linusbrendel 8 лет назад +3

      +Sklin pic or it didn't happen

    • @2nd_Channel
      @2nd_Channel 8 лет назад +1

      +Scotty Catman got the 1978 edition here :)

    • @angeldude101
      @angeldude101 8 лет назад +4

      I just realized the book is twice as old as me.

  • @adefunkeadedoyin9338
    @adefunkeadedoyin9338 Год назад +4

    Hearing C compiler was built with C,
    Wow!
    Building a sharper tool with a sharp tool :)

  • @bigbenhebdomadarius6252
    @bigbenhebdomadarius6252 8 лет назад

    Ah! I just happen to be re-reading Professor Kernighan's book, and here is this video. Yay!

  • @QumailReshii13
    @QumailReshii13 5 лет назад +2

    The man behind the "hello world" program. It's lovely to hear the story behind "C". Thanks to computerphile.

  • @leonstuij9540
    @leonstuij9540 4 года назад +5

    So they expected 5k books to be sold. How many did they actually end up selling?

  • @TheSpinTensor
    @TheSpinTensor 8 лет назад +15

    Theres a Raspbeary ;) on the shelf

    • @GBGSK
      @GBGSK 4 года назад

      Lol

  • @onaecO
    @onaecO Год назад

    The book he wrote changed the trajectory of my life.
    From 0 to developer and i am actually making a course on my channel about...Forever grateful!
    Brian Kernighan you will never read this but... you are the best!

  • @greybeardmc
    @greybeardmc 2 года назад +1

    And I bought K&R in December of 1979, read it over the Christmas break, wrote some programs on a notepad (literal paper notepad, not some app), then ran them when I was able to get back to the computer lab after break was over, and that's how I taught myself C (that and reading the 4.1/4.2 BSD source code)

    • @abednego8304
      @abednego8304 2 года назад +2

      Wow! Cool wish to meet you and learn from you

  • @pcuser80
    @pcuser80 8 лет назад +52

    The master himself :)
    I work all day with Linux so great..... (as a server)

  • @jsprite123
    @jsprite123 5 лет назад +17

    ...and thus 0-based index arrays began......................

    • @Deschutron
      @Deschutron 5 лет назад

      People usually like to start indexing things at 1 but when did they celebrate the start of the 21st century?

    • @starc0w
      @starc0w 5 лет назад +2

      Its a off-set from the first element. First element -> 1 + [0] = 1

    • @johnfrancisdoe1563
      @johnfrancisdoe1563 4 года назад

      jsprite123 PL/1 had them too, if I remember correctly (haven't used it since the 90s)

  • @bitterbob30
    @bitterbob30 3 года назад

    My all time favorite class in college was data structures using C. The first few weeks was banging my head into the desk, wall, anything else trying to figure out how pointers worked. With help from the K&R book it all of a sudden clicked and the class was a cinch after that.
    I'll never forget that sense of euphoria when I finally got my first linked list program to compile. There were plenty of other logic errors I had to iron out, but I knew those would be a piece of cake after overcoming the pointers stumbling block.

  • @patrickeh696
    @patrickeh696 5 лет назад +1

    The PDP-11. Still one of my all time favorite computers.

  • @daviddupoise6443
    @daviddupoise6443 8 лет назад +4

    I would watch Brian and these guys talk all frickin day long. I have such profound respect for the Unix crowd of the 1970s.

  • @robmckennie4203
    @robmckennie4203 8 лет назад +3

    Has there been a computerphile video on git? The people-talking-over-animation would be a good format for explaining git, i think

    • @Oshyrath
      @Oshyrath 6 лет назад +2

      Rob Mckennie in case of fire, 1) git add . 2) git commit 3) git push 4) leave building

    • @prudhvi9256
      @prudhvi9256 6 лет назад +1

      git commit -m"the building is on fire"

  • @scubaspi
    @scubaspi 8 лет назад

    I loved watching Brian's segment in AT&T's The Unix Operating System film which can be found on RUclips.

  • @yevhenukrainianer4781
    @yevhenukrainianer4781 5 лет назад

    Thanx, Brian & Dennis for my first fundamental book.

  • @Kneedragon1962
    @Kneedragon1962 8 лет назад +6

    That's a bit like finding and interviewing the guy who wrote Genesis...

    • @smurfyday
      @smurfyday 7 лет назад +4

      Except this language and person exists, and isn't a conglomerate of numerous story-tellers down the years.

  • @Henrix1998
    @Henrix1998 8 лет назад +47

    I still love Assebmly

    • @Ovenman940
      @Ovenman940 8 лет назад +8

      Henrix98 Assembly is still used in some industries. And yes, it's still great.

    • @christheother9088
      @christheother9088 8 лет назад +1

      Henrix98 Loved doing assembly on my Commodore 64. Programming in C is a close second.

    • @brys555
      @brys555 8 лет назад

      Henrix98 MOV!

    • @AntonAdelson
      @AntonAdelson 8 лет назад +3

      Henrix98 Embedded Assembly in C FTW!!

    • @linusbrendel
      @linusbrendel 8 лет назад

      +Anton Adelson +1

  • @supcompro
    @supcompro 6 лет назад +2

    crazy to think about just how old programming languages are, these days i always get caught up thinking that i am on the bleeding edge all the time

  • @charlesbaldo
    @charlesbaldo 5 лет назад

    Thank you Brian, your book created a carerr for me.