Live data from Hacker News

Infrequently Asked Questions in Comp.lang.c (1999)

seebs.net

21–30 of 45 posts

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#21

After reading through this, I'm not sure if it's a list of jokes or real information? For example: > long ints can be entered using hexadecimal notation; for instance, > long int foo = 07; How is this a good example of hexadecimal input?

You have asked question 19.27, by the way.

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#22

Great joke list. Though sometimes reality beats fiction > 1.6: I finally figured out the syntax for declaring pointers to functions, but now how do I initialize one? > With the assignment operator Well what did you expect right?!

Given how opaque the syntax is, expecting to have to use a screwdriver isn’t that weird…

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#23

After reading through this, I'm not sure if it's a list of jokes or real information? For example: > long ints can be entered using hexadecimal notation; for instance, > long int foo = 07; How is this a good example of hexadecimal input?

They also go me for a while (and I have C in my education but with C/C++ you never know for sure) but when Microsoft invented C I knew something was wrong.

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#26

After reading through this, I'm not sure if it's a list of jokes or real information? For example: > long ints can be entered using hexadecimal notation; for instance, > long int foo = 07; How is this a good example of hexadecimal input?

Just as a broken clock shows the correct time twice a day, you can use this syntax to input hexadecimal numbers less than 0A.

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#28

I don't want to be toxic but why make a function to cast a char to an int? I was astounded when I briefly skimmed through the list. I hope this is not curriculum in education.

I got the impression that the entire document is meant as a joke.

Unambiguously so if you click to any of the footnotes.

Re: Infrequently Asked Questions in Comp.lang.c (1999)

#29

After reading through this, I'm not sure if it's a list of jokes or real information? For example: > long ints can be entered using hexadecimal notation; for instance, > long int foo = 07; How is this a good example of hexadecimal input?

> After reading through this, I'm not sure if it's a list of jokes or real information? The whole point is pulling peoples legs, the joke being on the person who doesn't know the language well enough and takes it serious. The answers in the list are the equivalent of telling an apprentice to go get a can of blinker fluid (or Siemens Lufthacken, etc...), which they dutifully do and end up getting laughed at. E.g. just…

> a leading zero in an integer literal means octal. It compiles and works out, because `7`, `07` and `0x07` happen to have the same value

That is a hilariously beautiful and simple example to communicate that.

Post reply on HN