"The early days of Unix at Bell Labs" - Brian Kernighan (LCA 2022 Online) youtube.com/watch?v=ECCr_…
πŸ‘︎ 137
πŸ’¬︎
πŸ‘€︎ u/mttd
πŸ“…︎ Jan 16 2022
🚨︎ report
"The early days of Unix at Bell Labs" - Brian Kernighan (LCA 2022 Online) /r/unix/comments/s6iiyh/t…
πŸ‘︎ 5
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Jan 17 2022
🚨︎ report
Brian.W.Kernighan will give a keynote at linux.conf.au 2022 twitter.com/linuxconfau/s…
πŸ‘︎ 96
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Dec 18 2021
🚨︎ report
"The early days of Unix at Bell Labs" - Brian Kernighan (LCA 2022 Online) /r/unix/comments/s6iiyh/t…
πŸ‘︎ 18
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Jan 17 2022
🚨︎ report
"The early days of Unix at Bell Labs" - Brian Kernighan (LCA 2022 Online) /r/unix/comments/s6iiyh/t…
πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Jan 17 2022
🚨︎ report
"The early days of Unix at Bell Labs" - Brian Kernighan youtube.com/watch?v=ECCr_…
πŸ‘︎ 40
πŸ’¬︎
πŸ‘€︎ u/marekorisas
πŸ“…︎ Jan 17 2022
🚨︎ report
Brian.W.Kernighan will give a keynote at linux.conf.au 2022 twitter.com/linuxconfau/s…
πŸ‘︎ 49
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Dec 18 2021
🚨︎ report
Brian Kernighan's Home Page cs.princeton.edu/~bwk/
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/qznc_bot2
πŸ“…︎ Jan 07 2022
🚨︎ report
"The early days of Unix at Bell Labs" - Brian Kernighan (LCA 2022 Online)

The magnanimous ...the irresistible ...the geek personified....and an incredible story-teller ...Brian.W.Kernighan!! Take a peek his commentary at **#**lca2022

https://www.youtube.com/watch?v=ECCr_KFl41E

πŸ‘︎ 44
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Jan 17 2022
🚨︎ report
Which computer science courses does Prof.Brian Kernighan attend?

I was not able to find anything online :(

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/EIStiletto
πŸ“…︎ Dec 31 2021
🚨︎ report
Brian.W.Kernighan will give a keynote at linux.conf.au 2022 twitter.com/linuxconfau/s…
πŸ‘︎ 44
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Dec 18 2021
🚨︎ report
Brian.W.Kernighan will give a keynote at linux.conf.au 2022 twitter.com/linuxconfau/s…
πŸ‘︎ 47
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Dec 18 2021
🚨︎ report
AT&T Archives: The UNIX Operating System (1982) - contains interviews with Brian Kernighan, Alfred Aho, Ken Thompson, Lorinda Cherry youtu.be/tc4ROCJYbm0
πŸ‘︎ 57
πŸ’¬︎
πŸ‘€︎ u/PokerEnthusiast
πŸ“…︎ Sep 17 2021
🚨︎ report
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. β€” Brian W. Kernighan and P. J. Plauger in The Elements of Programming Style.?
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/basqueze7p
πŸ“…︎ Sep 11 2021
🚨︎ report
The Birth of UNIX with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 196
πŸ’¬︎
πŸ‘€︎ u/whackri
πŸ“…︎ Jun 26 2021
🚨︎ report
β€œA very helpful (Python) cheat sheet, quite long.” ― Brian Kernighan gto76.github.io/python-ch…
πŸ‘︎ 192
πŸ’¬︎
πŸ‘€︎ u/pizzaburek
πŸ“…︎ Nov 02 2020
🚨︎ report
Controlling complexity is the essence of computer programming. β€” Brian Kernighan?
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/grimshawl4g
πŸ“…︎ Sep 10 2021
🚨︎ report
Brian Kernighan interviews Ken Thompson. Not specific to C, but I figured everyone here would be interested in it. youtube.com/watch?v=EY6q5…
πŸ‘︎ 208
πŸ’¬︎
πŸ‘€︎ u/pmyourfoodpics
πŸ“…︎ May 12 2021
🚨︎ report
How did Brian Kernighan and Dennis Ritchie got SO MUCH right in the programming world?

Not so much of a question, just a fascination of their works. I haven't even read their full works. Yet I hear, read so much about them. All the time, more often than I can keep count. Also if any other personality I (programmers) should read. Many Thanks :)

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/stupidphilomath
πŸ“…︎ Apr 14 2021
🚨︎ report
C Programming Language | Brian Kernighan and Lex Fridman youtube.com/watch?v=G1-ws…
πŸ‘︎ 223
πŸ’¬︎
πŸ‘€︎ u/JavaSuck
πŸ“…︎ Jul 19 2020
🚨︎ report
An interview with Brian.W.Kernighan ..circa 2003 Linux Journal

Ah, a genuinely humble and a brilliant man,importantly one of my worshipped hero ,says it all. But also "Deglorifies" his all invaluable contributions to the computing industry,like, live in that special "league" ...

A salute!...You are awesome Brian!

https://www.linuxjournal.com/article/7035

πŸ‘︎ 44
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ May 22 2021
🚨︎ report
The Birth of UNIX with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 415
πŸ’¬︎
πŸ‘€︎ u/eis3nheim
πŸ“…︎ Nov 22 2020
🚨︎ report
What would you ask Brian Kernighan?

If you could ask Brian Kernighan anything (of K&R’s the C Programming Language, what would you ask him?

I’m looking for interview questions. If your question is picked i will give credit and upload the interview here!

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/stewpid0ne
πŸ“…︎ May 01 2021
🚨︎ report
Will Javascript Take Over the World? | Brian Kernighan and Lex Fridman youtu.be/AB60_uUetJs
πŸ‘︎ 11
πŸ’¬︎
πŸ“…︎ Jul 24 2020
🚨︎ report
itoa example code (Brian Kernighan and Dennis Ritchie Tutorials

Hi! I'm learning from an old C book off ebay.

Brian W. Kernighan and Dennis M. Ritchie (Pub. 1978)

I'm on the Control Flow chapter, Exercise 3-3. Where a modification to the itoa functions is required to allow for the whole range range of integer values, the example on the page will fail on -2147483648 as it overflows when the sign is removed as part of the solution.

I have put a case into the function where it checks whether the input magnitude is greater than the max positive.

This seems messy to me, can anyone think of a way make the solution more elegant?

My code is below, this is my first time posting on this subreddit - I already use reddit so thought I'd give this a try rather than stackoverflow :)

Any other advice is welcome, it goes without saying that I'm a noob.

Cheers

/*
Code to test the itoa function.
This is my solultion to Exercise 3-3 of "The C Programming Language"
by Brian W. Kernighan and Dennis M. Ritchie.
*/

#include<stdio.h>
#include<stdlib.h>

#define MAX 100
#define LOWLIMIT -2147483648
#define HIGHLIMIT 2147483647

char s[MAX];

// Function declaration
int itoa(int n, char* s);
void reverse(char* s);

int main(void)
{
  // Convert an integer to a string representation
  for(int i = LOWLIMIT; i <= HIGHLIMIT; i++)
  {
    itoa(i, s);

    puts(s);
  }

  return EXIT_SUCCESS;
}


// Integer argument is converted to a string representation
int itoa(int n, char* s)
{
  int i, sign;
  int max = 1;
  int temp = 1;

  // Left shift to get max possible size for input int
  for(i=0 ; temp>0; i++)
  {
    max = temp;
    temp = (temp << 1) + 1;
  }

  // Check if input is greater in magnitude than max value for positive
  // integer. If so, then return max negative.
  if(((sign = n) < 0) && ((-max) > n))
  {
    sprintf(s, "-2147483648");

    return EXIT_SUCCESS;

  } else if((sign = n) < 0)
  {
    n = -n;
  }

  i = 0;

  // Find remainder of division by 10 and add to ASCII code offset for
  // numeric symbols.
  // While there is still another order of magnitude, repeat the loop.
  do
  {
    s[i++] = n % 10 + '0';
  } while((n /= 10) > 0);

  // If the number was negative, then add a hyphen to the array
... keep reading on reddit ➑

πŸ‘︎ 7
πŸ’¬︎
πŸ‘€︎ u/Octo_Milk
πŸ“…︎ Dec 28 2020
🚨︎ report
CS50 Lecture by Brian Kernighan youtu.be/kw9KwjJCJH8
πŸ‘︎ 92
πŸ’¬︎
πŸ‘€︎ u/davidjmalan
πŸ“…︎ Sep 18 2020
🚨︎ report
Where GREP Came From - Brian Kernighan youtube.com/watch?v=NTfOn…
πŸ‘︎ 2k
πŸ’¬︎
πŸ‘€︎ u/PM_ME_YOUR_YIFF__
πŸ“…︎ Jul 06 2018
🚨︎ report
TIL the current hash function for Java strings is of unknown author. In 2004 Joshua Bloch "went so far as to call up Dennis Ritchie, who said that he did not know where the hash function came from. He walked across the hall and asked Brian Kernighan, who also had no recollection." [x-post /r/java] bugs.java.com/bugdatabase…
πŸ‘︎ 9k
πŸ’¬︎
πŸ‘€︎ u/walen
πŸ“…︎ Jun 12 2017
🚨︎ report
The Birth of UNIX with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 48
πŸ’¬︎
πŸ‘€︎ u/pgen
πŸ“…︎ Nov 22 2020
🚨︎ report
Brian Kernighan: UNIX, C, AWK, AMPL, and Go Programming | AI Podcast #109 with Lex Fridman youtube.com/watch?v=O9upV…
πŸ‘︎ 217
πŸ’¬︎
πŸ‘€︎ u/feketegy
πŸ“…︎ Jul 19 2020
🚨︎ report
Experience of Brian Kernighan on Rust youtu.be/O9upVbGSBFo?t=38…
πŸ‘︎ 57
πŸ’¬︎
πŸ‘€︎ u/lzutao
πŸ“…︎ Jul 19 2020
🚨︎ report
Brian Kernighan interviews Ken Thompson at Vintage Computer Festival East 2019 youtube.com/watch?v=EY6q5…
πŸ‘︎ 155
πŸ’¬︎
πŸ‘€︎ u/mttd
πŸ“…︎ May 07 2019
🚨︎ report
Enjoy! Invigorating ...The Birth of UNIX by Brian. W.Kernighan
πŸ‘︎ 42
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Nov 18 2020
🚨︎ report
The Birth of Unix with Brian Kernighan corecursive.com/brian-ker…
πŸ‘︎ 24
πŸ’¬︎
πŸ‘€︎ u/nixcraft
πŸ“…︎ Nov 22 2020
🚨︎ report
The Birth of UNIX with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 35
πŸ’¬︎
πŸ‘€︎ u/eis3nheim
πŸ“…︎ Nov 22 2020
🚨︎ report
The Birth of Unix with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 11
πŸ’¬︎
πŸ‘€︎ u/qznc_bot2
πŸ“…︎ Nov 22 2020
🚨︎ report
C Programming Language | Brian Kernighan and Lex Fridman youtube.com/watch?v=G1-ws…
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/messi00747
πŸ“…︎ Sep 18 2020
🚨︎ report
Brian Kernighan: UNIX, C, AWK, AMPL, and Go Programming | AI Podcast #109 with Lex Fridman youtube.com/watch?v=O9upV…
πŸ‘︎ 50
πŸ’¬︎
πŸ‘€︎ u/tinyatom
πŸ“…︎ Jul 20 2020
🚨︎ report
The Birth of Unix with Brian Kernighan corecursive.com/058-brian…
πŸ‘︎ 9
πŸ’¬︎
πŸ‘€︎ u/PatientModBot
πŸ“…︎ Nov 22 2020
🚨︎ report
Enjoy! Invigorating ...The Birth of UNIX by Brian. W.Kernighan /r/unix/comments/jw64ou/e…
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Nov 18 2020
🚨︎ report
Enjoy! Invigorating ...The Birth of UNIX by Brian. W.Kernighan /r/unix/comments/jw64ou/e…
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/unixbhaskar
πŸ“…︎ Nov 18 2020
🚨︎ report
Thank Brian Kernighan and Dennis Ritchie.
πŸ‘︎ 43
πŸ’¬︎
πŸ‘€︎ u/FatherOfGold
πŸ“…︎ May 26 2020
🚨︎ report
Brian Kernighan knows every algorithm
πŸ‘︎ 183
πŸ’¬︎
πŸ‘€︎ u/JavaSuck
πŸ“…︎ Feb 01 2020
🚨︎ report
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. β€” Brian W. Kernighan and P. J. Plauger in The Elements of Programming Style.?
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/loarp5h
πŸ“…︎ Sep 10 2021
🚨︎ report
Controlling complexity is the essence of computer programming. β€” Brian Kernighan?
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/neillvgh
πŸ“…︎ Sep 11 2021
🚨︎ report
β€œEveryone knows that debugging is twice as hard as writing a program in the first place. So if you're as clever as you can be when you write it, how will you ever debug it?” - Brian Kernighan
πŸ‘︎ 226
πŸ’¬︎
πŸ‘€︎ u/azzedine062
πŸ“…︎ Dec 09 2019
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.