tag:blogger.com,1999:blog-6329595.post2865447691664865771..comments2024-03-19T03:38:06.787-05:00Comments on Althouse: "The tools that Dennis built — and their direct descendants — run pretty much everything today."Ann Althousehttp://www.blogger.com/profile/01630636239933008807noreply@blogger.comBlogger61125tag:blogger.com,1999:blog-6329595.post-35774915053379980832011-10-15T15:04:47.642-05:002011-10-15T15:04:47.642-05:00"Unfortunately, the one legacy of K&R is ..."<i>Unfortunately, the one legacy of K&R is that to save space they moved open braces to the preceding line and that became a horrid format. </i>"<br /><br />I don't know whether to say<br /><br />Yes++;<br /><br />or if it should better be:<br /><br />Yes *= 1024;Kirk Parkerhttps://www.blogger.com/profile/05921711310191924997noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-2058675201900717332011-10-15T14:07:59.245-05:002011-10-15T14:07:59.245-05:00Remember, the foundation of a C++ class is an arra...Remember, the foundation of a C++ class is an array of pointers to functions.<br /><br />And I like '=' as an assignment. Beats the awkward ":=".<br /><br />I love assembly, but it's pretty damn difficult these days to optimize for modern CPUs. C/C++ is like a super macro assembler.<br /><br />Unfortunately, the one legacy of K&R is that to save space they moved open braces to the preceding line and that became a horrid format.Joehttps://www.blogger.com/profile/04450897654318345683noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-23885636957858454232011-10-15T13:04:33.750-05:002011-10-15T13:04:33.750-05:00MadAs,
Html entities are your friend:
<, writ...MadAs,<br /><br />Html entities are your friend:<br /><br /><, written as &lt;<br /><br />and<br /><br />>, written as &gt;<br /><br />(and of course the 'written as' parts are written &amp;gt; etc ad infinitem...)Kirk Parkerhttps://www.blogger.com/profile/05921711310191924997noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-63578895168894491062011-10-15T13:02:35.103-05:002011-10-15T13:02:35.103-05:00edwardroyce,
"the guy decided that the best ...edwardroyce,<br /><br />"<i>the guy decided that the best possible design involved an array of pointers to functions...... Yeah don't ask.</i>"<br /><br />No, this is eminently askable: there is certainly nothing wrong with that sort of design in places where it's really appropriate. And also (regarding "And you cannot obtain a valid pointer to a macro"): shouldn't that simply fail to compile?Kirk Parkerhttps://www.blogger.com/profile/05921711310191924997noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-40515544139094176202011-10-15T09:41:39.704-05:002011-10-15T09:41:39.704-05:00hmmm.....C code, and html don't mixhmmm.....C code, and html don't mixmadAsHellhttps://www.blogger.com/profile/01149940549262340795noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-36648902066662074152011-10-15T09:40:51.780-05:002011-10-15T09:40:51.780-05:00#include
main( )
{
printf("Goodbye, Den...#include <br /><br />main( ) <br />{<br /> printf("Goodbye, Dennis");<br />}madAsHellhttps://www.blogger.com/profile/01149940549262340795noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-60808858484442429982011-10-15T09:06:59.335-05:002011-10-15T09:06:59.335-05:00"For those of you who don't know C, don&#..."For those of you who don't know C, don't worry about it."<br /><br />Yeah C needed a better assignment operator than "=". Then again COBOL needed a better statement terminator than ".". The smallest possible bit of punctuation. Seriously. I can't remember the number of times I've pored over program listings looking for a misplaced "." or two. Ugh.<br /><br />Then again my favorite bit of C silliness was, and this was a few years ago so my memory might not be as accurate as I would wish, obtaining a pointer to a function.<br /><br />I had to help a co-worker debug a particularly ugly program where the guy decided that the best possible design involved an array of pointers to functions.<br /><br />... Yeah don't ask.<br /><br />Well the guy forgot that some library functions weren't actually functions but macros. And you cannot obtain a valid pointer to a macro. So occasionally his program would either start doing some crazy stuff or just completely crash.<br /><br />300k of code in a single file. Code review; save your sanity. :)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6329595.post-13156257364935686472011-10-15T08:03:17.992-05:002011-10-15T08:03:17.992-05:00I completely agree about the importance of Dennis ...I completely agree about the importance of Dennis Ritchie's contributions to the programming world.<br /><br />I would also like to add a note of thanks to his colleagues who are still with us--who perhaps deserve to be better known while they're still around to appreciate it.arkhttps://www.blogger.com/profile/18246896789315209359noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-86401166215447226642011-10-15T04:26:30.234-05:002011-10-15T04:26:30.234-05:00"... programming webapps using RPG "
Oh..."<i>... programming webapps using RPG </i>"<br /><br />Oh. My. Gosh.<br /><br />Might as well use Klingon. <br /><br />Oh, wait--RPG <i>is</i> Klingon, isn't it?Kirk Parkerhttps://www.blogger.com/profile/05921711310191924997noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-45528810589760428022011-10-15T00:54:54.659-05:002011-10-15T00:54:54.659-05:00Long time reader, first time commenter.
Thank you ...Long time reader, first time commenter.<br />Thank you for bloggin on this Ann. The fact you hadn't heard of Ritchie before proves something about your instincts for what's important or something.<br /><br />For the nerds,<br />main( )<br /> {<br /> printf("hello, world");<br /> }<br /><br />And for those who want to learn more: http://en.wikipedia.org/wiki/Hello_world_program400 bad requesthttps://www.blogger.com/profile/07725641626503105594noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-46874612873570567612011-10-15T00:41:16.706-05:002011-10-15T00:41:16.706-05:00J thinks a logical positivist has something to do ...J thinks a logical positivist has something to do with binary. Tee hee.Quaestorhttps://www.blogger.com/profile/13688608372863540573noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-40499781543269432342011-10-14T23:48:18.477-05:002011-10-14T23:48:18.477-05:00I must admit I'd never heard of the man
Just ...<i>I must admit I'd never heard of the man</i><br /><br />Just one of those things about how the world works. More noticeable this month than last because he was in the same general field as someone who was far more famous.Stevenhttps://www.blogger.com/profile/05138730966226244399noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-57502752578000997542011-10-14T23:44:08.899-05:002011-10-14T23:44:08.899-05:00Rest in peace.Rest in peace.Revenanthttps://www.blogger.com/profile/11374515200055384226noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-43945770141674447002011-10-14T22:13:46.881-05:002011-10-14T22:13:46.881-05:00No, Byro Sorepaw the t-shirt boy--yr the disgrace,...<b>No, Byro Sorepaw the t-shirt boy--yr the disgrace, no matter how many names you use, wicca-queer. No be sure to wiki bit vs byte, phony,</b><br /><br />J is so deluded that he imagines all of his critics are the same person.<br /><br />And he wouldn't know a byte if it bit him.sorepawhttps://www.blogger.com/profile/05897026983666453798noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-80978239479275584272011-10-14T21:49:35.692-05:002011-10-14T21:49:35.692-05:00C is for sissies. Real men still program in Fortra...C is for sissies. Real men still program in Fortran.Smilin' Jackhttps://www.blogger.com/profile/01501763605001379362noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-39547196432336081482011-10-14T21:46:27.353-05:002011-10-14T21:46:27.353-05:00Both C and Unix are elegant. Elegant implies as s...Both C and Unix are elegant. Elegant implies as small and simple as possible, no clutter. Not only is this more beautiful but the smallness and simplicity of C and Unix make them simpler and cheaper to implement.<br /><br />Maybe the key concept in making them elegant was defining a small, powerful set of core mechanisms and then reusing those mechanisms over and over and over.<br /><br />You see that same idea in architecture.Steve Kochhttps://www.blogger.com/profile/13077530042599697923noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-14384000698248825562011-10-14T21:42:15.546-05:002011-10-14T21:42:15.546-05:00“It lets you get close to the machine, without get...<i>“It lets you get close to the machine, without getting tied up in the machine.”</i><br /><br />This is the best short answer to the <i>what the hell is C, and why is needed?</i> question. Getting "tied up in the machine" means programming on the CPU level, often called Assembly Language or just Assembler. The most valuable courses I took as an undergrad involved programming in Assembler. Learn how to do that and all the mystery of the black box -- the Intel or AMD chip at the heart of that thing on your desk on your lap -- evaporates. Assembly language is a mighty hard way to get anything practical done with a computer because it is so alien to the way we normally thing about a task. People apply intelligence, insight and intuition to everything we do. Computers have none of those qualities, in spite of whatever illusions a clever programmer can cook up. Assembler also permits the programmer to force an issue with the system if there's a subtle flaw that evades his analysis. If your program always cashes and dumps at the same point because it must have F0F0 at relative such-and-such then you can fix it quick and dirty by writing a bit more code that puts that value there when its needed. This called hammer-lock programming, or putting a gun to the f*cking thing's head.<br /><br />Before Ritchie most software was written is some flavor of BASIC, COBOL or FORTRAN, and most programmer never touched a project that required a lower level approach. They're all pretty similar with strengths in various fields, COBOL for banking, insurance, etc. FORTRAN for engineers and scientists, BASIC for everybody else, kinda like the three estates of feudal France. The advantage is that the code looks sorta like English and the logic is pretty clear for another programmer, or even a non-programmer to follow. The problem is that since loose and fluid human reasoning seldom coincides with the deterministic and thoughtless logic of the computer the human-like language of COBOL complies to a huge mess of machine code which is inherently inefficient and hard to debug. When COBOL was invented in the 1950s it when for years with subtle errors in the standard compiler, so a one could write a perfectly logical and evidently flawless program and have it fatally corrupted by the compiler. This is the origin of the apocryphal stories of people getting billion-dollar electric bills and such.<br /><br />The huge size of even simple programs authored in COBOL wasn't an issue when every computer was a building-sized system build by IBM or Univac, they have enough resources (very expensive resources, mind you) to cope with the inefficiencies. But when minicomputers started appearing the limitations of the high-level languages became critical. If you wanted to something really useful with a PDP-series system you needed to program it on the CPU level. Then C appeared, and the mini became a contender. C was the trump of doom to the huge institutional machines like the 360s and the Burroughs 6000s. Suddenly a box the size of a refrigerator could do what a machine that need a building size of an average house had been needed to do.Quaestorhttps://www.blogger.com/profile/13688608372863540573noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-3560943261492865632011-10-14T21:35:11.639-05:002011-10-14T21:35:11.639-05:00True, Big Mike.
IIRC, one reason that the compute...True, Big Mike.<br /><br />IIRC, one reason that the computer science guys went to C and Unix is that a C compiler was always available for C for unix operating systems. You could write device drivers in C for unix, which made it easier to add and control new devices. <br /><br />Otherwise you had to write the device driver in an assembly language, which varied from computer architecture to computer architecture.<br /><br />IIRC, the source code for unix was available very early on. Unix could be studied and modified. <br /><br />So unix helped C spread and C helped unix spread.Steve Kochhttps://www.blogger.com/profile/13077530042599697923noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-72539027088410007512011-10-14T21:17:41.123-05:002011-10-14T21:17:41.123-05:00@LakeLevel, C may not have been ambiguous, but the...@LakeLevel, C may not have been ambiguous, but there's no such thing as a C programmer who hasn't, many times!, written<br /><br />if (a = b) <br /><br />instead of<br /> <br />if (a == b)<br /><br />For those of you who don't know C, don't worry about it.Big Mikehttps://www.blogger.com/profile/15831645119853118904noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-14128401914756174572011-10-14T21:15:15.622-05:002011-10-14T21:15:15.622-05:00But everybody knows who "Snooki" is.
We...But everybody knows who "Snooki" is.<br /><br />We're so fucked.Wincehttps://www.blogger.com/profile/15002449963597087316noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-80383090102615867652011-10-14T21:09:40.558-05:002011-10-14T21:09:40.558-05:00All I remember is that in Pascal and Cobol et. al....All I remember is that in Pascal and Cobol et. al., if you had a syntax error, you had to actually look through and understand all the code to figure out where the error was. C was a godsend. the syntax was simple and not in the least ambiguous. That is the reason everyone after has modelled their language syntax after C. Thanks dude. Vaya con dios.LakeLevelhttps://www.blogger.com/profile/00589622948142663892noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-28081485114838138662011-10-14T21:08:17.327-05:002011-10-14T21:08:17.327-05:00J,
... though most don't know a bit from a byt...J,<br /><i>... though most don't know a bit from a byte.<br /></i><br />We can tell a butt when we see one, though.marinerhttps://www.blogger.com/profile/03435598676103731157noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-73120419331676317042011-10-14T21:03:20.684-05:002011-10-14T21:03:20.684-05:00"i don't have any idea how that mess was ..."i don't have any idea how that mess was untangled."<br /><br />Depends on whether that was before or after IBM introduced the punch card sorter. And I'm way too lazy right now to wiki it or google it.<br /><br />I'm pretty sure I've never had to deal with pre-sorter on punch cards.<br /><br />On the other hand some recruiter tried to convince me that going back to the AS/400 and programming webapps using RPG was a -good- idea.<br /><br />I ain't that dumb. Close. But no cigar. :)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6329595.post-63761737509197111782011-10-14T20:55:11.524-05:002011-10-14T20:55:11.524-05:00... though most don't know a bit from a byte.
...<b>...</b> <i>though most don't know a bit from a byte.</i><br /><br />Nor do you, J, nor do you.Big Mikehttps://www.blogger.com/profile/15831645119853118904noreply@blogger.comtag:blogger.com,1999:blog-6329595.post-51347298982688782882011-10-14T20:52:24.884-05:002011-10-14T20:52:24.884-05:00No, Byro Sorepaw the t-shirt boy--yr the disgrace,...No, Byro Sorepaw the t-shirt boy--yr the disgrace, no matter how many names you use, wicca-queer. No be sure to wiki bit vs byte, phony<br /><br /><br />'bout Annie time, flunkie---ahhyeah...that's <i>user friendly.</i>Jhttps://www.blogger.com/profile/11567400697675996283noreply@blogger.com