Ask Slashdot: Have You Read 'The Art of Computer Programming'? (wikipedia.org)
In 1962, 24-year-old Donald Knuth began writing The Art of Computer Programming, publishing three volumes by 1973, with volume 4 arriving in 2005. (Volume 4A appeared in 2011, with new paperback fascicles planned for every two years, and fascicle 6, "Satisfiability," arriving last December). "You should definitely send me a resume if you can read the whole thing," Bill Gates once said, in a column where he described working through the book. "If somebody is so brash that they think they know everything, Knuth will help them understand that the world is deep and complicated."
But now long-time Slashdot reader Qbertino has a question: I've had The Art of Computer Programming on my book-buying list for just about two decades now and I'm still torn...about actually getting it. I sometimes believe I would mutate into some programming demi-god if I actually worked through this beast, but maybe I'm just fooling myself...
Have any of you worked through or with TAOCP or are you perhaps working through it? And is it worthwhile? I mean not just for bragging rights. And how long can it reasonably take? A few years?
Share your answers and experiences in the comments. Have you read The Art of Computer Programming?
But now long-time Slashdot reader Qbertino has a question: I've had The Art of Computer Programming on my book-buying list for just about two decades now and I'm still torn...about actually getting it. I sometimes believe I would mutate into some programming demi-god if I actually worked through this beast, but maybe I'm just fooling myself...
Have any of you worked through or with TAOCP or are you perhaps working through it? And is it worthwhile? I mean not just for bragging rights. And how long can it reasonably take? A few years?
Share your answers and experiences in the comments. Have you read The Art of Computer Programming?
Unfortunately no and I have a reason:
Reading those books requires high degree of mathematical sophistication, particularly, knowledge of complex analysis, which I lack.
Two decades THINKING about buying books? Jesus Christ. Just go buy them. You are ridiculous.
I still have it at my desk, though I only have the 4 volume set.. I think its been slightly expanded a few times in the past decade. And yes, I actually enjoyed reading through it a few times
No.
We now know what goes on in yours
empress? memcached? redis? You guys have strange names for programs.
I read the first three books in University and did examples from the first two when I started debating with myself, friends and professors, is it better to have the ultimate reference or be able to create code on your own as the requirements come up?
Over the thirty plus years since, I'm happy to say that volume two and three have gotten pretty ratty as I've used them as references (along with "Programming in C", 2nd edition) so I feel like I've struck the right balance (for me) between reading them, using them as reference and creating my own code/algorithms.
Mimetics Inc. Twitter
Although she preferred his other works, like The Land Before Time and Anastasia.
#DeleteChrome
And all I got was a tshirt.
Just buy it (the entire and updated book set) and read it ;) and continue to use it as a permanent reference for whatever you want to do with programming...
It's really great reading if you do stuff like program low-level (think C, Assembler), efficient programming or do stuff close to the hardware level (such as microprocessors). It describes the very low level of a program and a computer.
If you're into a higher level of programming (Java, C#, Python etc), unless you're building libraries for it, it is probably going to confuse you, most of the 'hard stuff' is (double precision, floating point, sorting and searching through lists ...) abstracted away. Obviously 'someone' has to know how it works in the end, someone has to write the compilers, I haven't started on the rest of the volumes because that's not "me".
You should understand how computers work before you start reading these, I've been in the 'business' for 20 years, I've read it 3 times just to get a basic grasp on the first volume.
Custom electronics and digital signage for your business: www.evcircuits.com
It isn't terribly complex now that geniuses like Knuth have spent literally decades simplifying it for you, sure. Step deeper into the world and you'll be truly amazed at how deep it is ... and likely staggered that it works as well as it does.
"Glory is fleeting, but obscurity is forever." - Napoleon Bonaparte
I read the three volumes like I read any book in SkyRim: I opened the cover, got my +1 level in computer science, dropped it and hit it with a fireball.
It's definitely worth reading, and working through at least some of the exercises. It is an excellent example of rigor, depth, and attention to detail. You may not have time to work like that every day, but it's very useful to be capable of doing it and to have a good mental model of what it's like.
You think anything written by anybody 77 years old is relevant?
So I take it you think K&R is irrelevant as well.
#DeleteChrome
TAOCP is a great reference. There are some really important things that are pretty good for someone who wants to be a professional software engineer.... 0) understanding how algorithms execute on a processor. While MIX is behind the times, (and MMIX is ahead of the times in many ways) understanding how an algorithm executes on a processor is important. I think Knuth really did the right thing in not selecting the language of the day. 1) algorithm reference. If you need to understand an algorithm, or choose between a family of algorithms, it is often a great place to find the art. 2) The humor is pretty good, at least to me. Done get me wrong, it's on a humor book, but there is wittiness and puns and some running gags... 3) It's always good to have some humility, and reading TAOCP always makes me a little more humble. It's worthy of a place on your shelf.
-- Erich
Slashdot reader since 1997
Driving a car isn't hard millions do it. But how many drive in NASCAR?
Sure, yeah, you could take a few weekend courses and bang out some stuff and possibly even find a job paying decent money.
But if you want to move up in the world you need to turn your hack and slash techniques into a refined art.
The kind of crap commodity programmers write is the stuff that skilled developers get paid a lot of money cleaning up or just re-implementing.
It the difference between dime store trashy romance novels and real actual novels. The different between the the Divergent movies and Hunger Games.
If you're content being a direct to DVD wholesaler of crap sure, just get to work.
If you want to work in the big leagues on important things, you need to be open to learning some things and respect the craft.
Work Safe Porn
Nah, I've been programming longer than Knuth has, starting with machine language. You just need to think procedurally.
It's not complex if you merely want it to run, but if you want flexible, maintainable, and readable code, then it is complex.
Table-ized A.I.
I thought everyone learned from a Dummies book and building a few cell phone flashlight apps.....
Tens of thousands. How many people have walked on the moon wearing blue underwear? I can ask irrelevant questions too.
No, but the poser child from a private university that is friend of the boss claims that will publish erratas to all volumes available or when they are published.
Disclaimer: Post this as "funny" but this actually happened with some dork project leader in Java from a consulting firm around 2006.
I used Vol. 2 to improve the multiply algorithm in an open source program.
I have them. I have studied small parts of some of them. I have been delving into them over 30 years.
For day to day programming, I do not need or use the detail in those books.
At various times in the past, I have delved into library writing, and then they were very helpful, mostly in understanding issues and problems that I had not thought about. But I think time has moved on. Hardly anyone needs the details in those books, and in many cases, some classes of problems are well solved.
Looking back, I am glad that I studied some parts. But today I would not recommend them. Unless you really wanted to look back at history.
The writing style has much to be desired. The code fragments do not follow any of the modern practices. Heck, if I remember it correctly, Knuth actually starts by explaining what pseudo code is and how it is for some imaginary machine to illustrate the point. These books were not written for the modern audience. His audience were his contemporary who worked with computers. Those people typically had a background in math and not in computer science. And the computers they used required very different kinds of considerations since memory and cpu were very expensive and you had to make your algorithms work under tight constraints. So the algorithms are cryptic not just because good languages did not exist back then, but because Knuth writes them in such a way as to run in a few KB of memory...because that is just how you wrote code in those days...worrying about where on disk the data resides and how to take advantage of the next memory location that the data resided on.
This is not to say that the Knuth doesn't know what he is talking about. But rather the knowledge he presents is now also possessed by many others who can articulate it better. Do yourself a favor and stay about those books. The subject matter has been covered to death in many other books. And understanding it will not turn you into some kind of a CS god, thought you may get the same kind of satisfaction a person could get from completing a marathon or climbing Everest.
This book is to computer programming as quantum physics is to rebuilding a car motor.
Your closed source code is full of malware. No one should use it.
Many people can learn to program in well developed environments with sophisticated debugging tools, rich base classes, and optimized compilers.
Most people cannot program without those tools, and they know very little about machine language and how the computer or OS they are targeting actually works under the hood.
So saying programming isn't terribly complex just doesn't mean very much without some context.
Nah, sure they can. It isn't terribly complex. Even kids can program to some degree.
It isn't terribly complex now that geniuses like Knuth have spent literally decades simplifying it for you, sure. Step deeper into the world and you'll be truly amazed at how deep it is ... and likely staggered that it works as well as it does.
+1. Programming isn't terribly complex if you always do it with your training wheels on, and if you never write anything that hasn't been written a hundred times before.
When all you have is a hammer, every problem starts to look like a thumb.
Nah, it has never been terribly complex. Even before we had compiled languages it wasn't terribly complex.
Nah, I've been programming longer than Knuth has, starting with machine language. You just need to think procedurally.
In your case, it sounds more like "sporadically".
When all you have is a hammer, every problem starts to look like a thumb.
Nah, not really. It might be hard for you, but you might be a muddled thinker.
It depends on what you mean by "work through it". Do all the exercises? Some are unsolved problems, so that's not terribly realistic.
There's nothing in the books that's not also discussed elsewhere (with the possible exception of the very thorough discussion of out-of-core sorting with tapes, which is a bit unusual these days), but it takes quite a few other books to equal the series.
I have read it at length, and it's definitely full of good stuff to know, but it really depends on your field. It's still dedicated to single-threaded algorithms, so concurrent and functional data structures aren't touched. If you're slinging matrices around for computer graphics, not so much.
But I definitely feel that it covers a greater span than, say, the CLR textbook Introduction to Algorithms.
Why don't you read some in a library (or download some of the torrents floating around) and see what you think? It's a reference book, not a mystery novel which isn't nearly as good if not read in order.
Overrated? I thought it was obsolete -- post "Goto Considered Harmful" back when Vol 1 was assigned in a university course -- 40 years ago.
OK, there is insight into algorithms, but from a programming best-practices standpoint, it is just not there. Even assembly language offers structured branching and looping. And if your macro assembler doesn't, structured branching and looping is a good practice for arranging your JMP statements. Simply taking JMPs into and out of your main loop was never a good practice to confer clarity of what your algorithm is doing, let alone establish provable conditions your code meets.
See subject 110010001000 & https://www.virustotal.com/en/... (Verified by Malwarebytes' S. Burn "seen the code & it's safe" http://forum.hosts-file.net/vi... )
* Libel will get you NOWHERE vs. facts you can't validly technically overcome loser... lol!
APK
P.S.=> Face facts you FAKE NAME online using fool (for your FAKE life) - you WISH you were me... apk
I don't know when Knuth started (prob before me) but I started in '71 am still doing it professionally. I've read other classics but only skimmed small bits of his work. Lots out there to learn, particularly in niche programming.
Don't get me wrong, Knuth is a genius. If you need to do deep research on sorting algorithms, definitely read it. If you want to do CS research and need to learn how to read research papers, its a good start. But you aren't going to get any deep insights on how to write a good program from it. Its too academic and far too focused on deep research. And even for the topics it does cover, unless you want to do research on how to really optimize the hell out of them you're better off using tutorials written for a more practical level.
I still have more fans than freaks. WTF is wrong with you people?
I can program in 6502, Z80, x86 and 680x0 assembly languages. Knuth doesn't deserve any thanks.
Read at least the first volume, even if you have to check it out of a library.
i am so very tired....
Nah, it's easy if you're as smart as I am.
Hmm. Have you taken Numerical Analysis?
...reading through thread: you really like the word nah as a sentence opener, don't you?
Driving a car isn't hard millions do it.
I've waited until I was 37-years-old to learn how to drive. My father wasn't going to teach me as a teenager to drive stick on his one-ton flatbed that he put a million miles on in ten years. Since Silicon Valley has a well-developed transit system, I got around just fine without having a need for a vehicle. One day my father abandoned his old car in my carport. I had not choice but to get my driver license and take possession of the car. Took me three years to find out about all the repairs that he didn't tell me about. It's easier to own a car when you're more mature and financially responsible, especially if your father is DIYer who doesn't believe in mechanics.
I wasn't sure if I'd read 'em. I know a friend/colleague (who I regard highly) who has - and I think he thinks highly of them. But he also has terrible taste in movies.
A quick google search landed me at http://broiler.astrometry.net/...
I have not read it.
I've been coding professionally for 25-30 years, depending on how you count. I studied CS in college. I've read a few outstanding books on the subject since then.
I don't have the patience for these, and I suspect I'm not going to miss out on much.
On the other hand, I long ago came to the conclusion that I'm really not interested in low level code. Give me a nice high level language with nice high level functions and features and I'm a happy coder. That's not to say that I don't understand O notation or the costs behind the complexity - but it is to say that I know when to use a drill and when to use a power saw - but I don't want to build either of 'em.
Maybe you're into the nitty gritty. Or maybe you like bad movies.
Check your local tech library and see if you can check out a copy. Or ebay 'em for $20-40/volume. Or if the pdf strikes your fancy, maybe take the plunge.
My wife and I each had a copy of the first three volumes when we married. Yes, there are female computer nerds. B-)
I first encountered it when assigned one of the volumes as a text back in 1971. Of course the class didn't consist of learning EVERYTHING in the volume. B-)
I use it from time to time - mainly as a reference book. Most recently this spring, when I needed a reference on a data structure (circular linked lists) for a paper. I've found it useful often when doing professional computer programming and hardware design (for instance, where the hardware has to support some software algorithm efficiently, or efficient algorithms in driver software allow hardware simplification).
I don't try to read it straight through. But when I need a algorithm for some job and it's not immediately obvious which is best, the first place I check is Knuth. He usually has a clear description of some darned good wheel that was already invented decades ago, analyzed to a fare-thee-well.
I only see him about once a year. He's still a sharp cookie.
Bantam Dominique roosters crow a four-note song. Once you've heard it as "Happy BIRTHday" you can't NOT hear it that way
110010001000 caught at work
That's why you're a garbage programmer Larry...that and you're on Slashdot all the time.
Seriously, if you don't step it up, we're going to have to let you go.
-Your boss, who knows what sites you go to
I've read the 1973 editions, cover to cover. I skimmed a few fasciles. Haven't kept up since then.
Do I recommend it? You bet I do, just like I recommend Structure and Interpretation of Computer Programs, The Mythical Man-month, and The Psychology of Computer Programming. That's not to say you have to have read classics like these to be a good programmer, but if you haven't internalised a lot of the material that's covered in books like these, I question how much you care about what you do. And if you don't care about what you do, it will show in the quality of your software.
sub f{($f)=@_;print"$f(q{$f});";}f(q{sub f{($f)=@_;print"$f(q{$f});";}f});
We should all chip in and get a complete set for the US Patent office. It might help them get rid of some bad patents they have issued over the years.
Or if you say you are using a computer in a patent app and don't cite Knuth as prior art for something you get tossed for that as well.
I hate reading book series when they're not finished yet. I'll wait until it's all out and then start. :)
Seems interesting and well-written, but too outdated and long to devote significant time to now.
Has some neat math in there, but really if I'm looking for that I'm just going to read a math book.
How long have you been working at Microsoft?
While I haven't read the books, and doubt I ever will now, the content is similar to the uni course I did in computer science back in the 80s. Knuth covers everything in higher detail than I can recall being taught, but I'm pretty certain my foundations are just fine. It may just be that I'm forgetting some things too, it's been almost 30 years now for most of it.
I might go back and revise a topic or two in those books or a similar source if I felt I needed a refresher. For most cases though, what I can recall is good enough to get through to the solution - or lead me to an online source to crib up on how best to form the solution.
I think if they spent more time today teaching this foundational science in classes, and less time on the latest languages and frameworks, then we'd be seeing a much better class of programmer emerging from education today.
All those moments will be lost in time, like tears in rain.
his hosts program is actually pretty good by xenotransplant
his hosts tool is actually useful for those cases in which one does indeed want to locally block stuff outright while consuming minimum system resources by alexgieg
I've never tried to belittle (APK's) work, I've flat out said it's good by BronsCon
take a look at the APK hosts file engine by SuperKendall
APK is kinda right. I've tried his hosts file generating software. It works by bmo
APK is totally right on this count. Adblock Plus on Firefox mobile is a dog on older, or lower end, phones. A hostfile based adblocker makes for a much better experience by chihowa
I like your host file system by Karmashock
I find your hosts file admirable by vel-ex-tech
* My code's liked/used + recommended & hosted by Malwarebytes' hpHosts - Argue w/ those folks above (or success).
APK
P.S.=> I have more like 'em if anyone asks (many more).... apk
Hmm. Have you taken Numerical Analysis?
It's quite clear that he (she, it?) has never studied computer science at all.
When all you have is a hammer, every problem starts to look like a thumb.
It's that kind of mentality that has given birth to a plethora of buggy, unmaintainable code that's ridden with security holes.
It is like asking if you have read the encyclopedia Britannia. I bought sorting and searching as one of my first real computer books in 1981. I read the sorting chapter carefully and coded the examples. I found it very useful to understand how many different ways exist to do something.
It caused me to have an open mind because I know I would never have thought of all the different ways to sort data. So I know for any complicated problem I haven't thought of all the ways that it can be done.
You don't have to work through every problem to get something out of the books. As Knuth says himself, some of the problems are actually good candidants for PHD dissertations.
I can program in Z80 and 6502 assembly,
Rodnay Zaks deserves a great deal of thanks -.o;
"You have to know how things work on a star ship". So true. Folks can wield the latest programming environment and call themselves programmers, nay, software engineers, and accomplish wondrous things. But do they know HOW it works? Likely not. Then some high schooler figures out how to suborn it and cause havoc or make money off it thereby. Because they know how it works.
It's a shame that DK got distracted by Typesetting and TeX for so long. The shaving of such a shiny yak probably lost so many bright minds.
Where's my hallowed copy of Struble?
I bought all three volumes for an ungodly price, thinking it would deftly refine my knowledge of programming. Instead, I got slapped in the face by some wicked esoteric math describing computing. What I did learn is that there is a HUGE difference between Computer Science from the 60's and programming, and that was in the 90's. [I worked at Intel as a DA (cad programmer) in the 90's for a while and brought these books in and asked around, no one could explain them to me. Hundreds of programmers, none understood the books.]
Today? The two barely even meet anymore. Programmers generally don't know dick about compsci. And these books have largely served as namedropping items to put on blogs or CV, because only a very few people I've met in my life have actually understood these books.
Yes, I sound bitter. Because I think we're losing the value of the foundations of CompSci Knuth poured, and I include myself in that condemnation. I wonder how much better a programmer I would have been had I been able to understand these books.
through the first three volumes. They are now a permanent fixture on the book shelf of my work desk at home.
They're completely correct.
Programming in itself is not very hard. Anyone can do it. Though only a few will be interested enough to keep doing it long enough to get good at it.
You can try to make yourself feel superior by pretending it's some sort of holy art. But it's not, it's really not.
Certain things you may want to _do with it_ might be hard, but that doesn't make it hard.
Winning a rally is hard. Winning a rally requires driving, but it doesn't follow that driving is hard. If you think that the fact that solving a particular class of problems via programming is hard that therefore programming is in itself hard then either 1. You haven't been programming very long, or 2. You really _shouldn't_ be programming. Or 3. Both.
Programming being easy doesn't mean that books like TAOCP aren't worthwhile - they definitely are. Because something can be pretty easy, but still have plenty of scope for you to learn and improve, and find better techniques.
I've been programming longer than Knuth has, starting with machine language.
If it's not a rude question, how old are you, exactly?
sub f{($f)=@_;print"$f(q{$f});";}f(q{sub f{($f)=@_;print"$f(q{$f});";}f});
Well, you have to start somewhere. Why not by reading TAOCP? Can't be terribly complex.
Folks, we live in an age where programmers declare integers that are going to count from 1...10 as LONG INTEGERS, eating 8 bytes of RAM, where only 1 byte is needed.
We live in an age of cloud computing, load balancers, containers, and distributed databases with stored procedures. When code runs, you have no idea where it is running and how it is spread out over cloud services. Most of the time you don't even know what country the physical box is in.
I have a pure CS degree, but as long as we can keep making things faster and bigger, I am not sure if this book will ever be a top seller. In the brave new world of computing I am not even sure what optimization means anymore. Optimize for CPU, network, compiler, database, cloud architecture??? It is maddening!
As for me, I am currently doing an embedded systems project. Am I doing it in 'C' and ASM like in the good old days? Heck, no, I am using python on a quad core ARM SOC with 1GB of RAM. Even at max processing load I am barely hitting 10% CPU while coding in Python. As long as hardware is fast and cheap, there is no need to spend this kind of time optimizing every cycle and byte. BTW, this is my first Python project. Easy-peasy language that is great for hardware interfacing projects, most libraries exist for common chips like the MCP3008 (AD convertor).
To the kids out there. This is a great time to be alive. You can build anything, learn anything, and talk to anyone. Do cool stuff. Learn everything. There are no limits and powerful hardware is cheap. Look around at how lucky you are to be alive right now. It is an amazing time!
The programming mechanism used is irrelevant to the contents of the volumes. When Tony Hoare introduced Communicating Sequential Processes (CSP), it was meant as a tool to reason about parallel computing. Then some misguided people thought it was about software, and that led to the rendezvous in Ada--a real setback.
Just buy the volumes, read them at enough depth to know what's in them, then they are a stupendous reference source. Need to know how to sort 7 items without a loop at lightning speed? There you go. Need an explanation why your program gets wrong numerical answers that make crappy graphics? It's in there. What's the best data structure and associated algorithms for your application? Help is on the way. Like others have noted, the hardback volumes actually wear out physically from use by people who must write the best software. Anyone can write crap after a short course at some for-profit "college", but if you want to be a star you need to know much, much more.
I get laughed at when I suggest memcached because all the cool young programmers "know" that redis is where it's at.
I had to look up this "redis" thing. I saw on the front page that it supports geospatial data. Then I looked up what constitutes "geospatial data" as far as redis is concerned. Then I cried a little.
It might be a fine product at what it was designed for, but any time I see people throwing around big words that they don't understand, it's a safe assumption that what they're trying to sell me is a toy.
sub f{($f)=@_;print"$f(q{$f});";}f(q{sub f{($f)=@_;print"$f(q{$f});";}f});
Is that you Nike/Shia? :P
Ant(Dude) @ Quality Foraged Links (AQFL.net) & The Ant Farm (antfarm.ma.cx / antfarm.home.dhs.org).
In that case you're probably better off reading this book...
No there's no way I came anywhere near mastering all of it. I worked through some parts that were important general background or relevant to what I was doing, read through the rest well enough to have a reasonable picture of what was going on most of the time. There were some parts that were completely over my head but I learned a lot solidly, and a lot more well enough to have a wide overview and know where to look if I ran into that type of problem later. Someone who really understands everything in the books (I think it is doable) is more likely to be a mathematician than a programmer.
Some parts of the series are now pretty dated, like the original MIX computer (now replaced with MMIX), or the huge section of Volume 3 devoted to sorting and merging data using tape drives (yes, today "disk is tape", but it's different at that level). Many other parts are more of mathematical than practical interest. The math in a lot of it is quite advanced, "math grad student" level rather than "CS undergraduate" level.
There's what amounts to an abridged edition that's more accessible, called "Concrete Mathematics" by Knuth, Graham, and Patashik. It's also a good book. It's basically a more relaxed recap of the foundational stuff in volume 1, and the important parts of the other 2 volumes. That's a better choice for an undergrad CS class.
The whole series though is quite old fashioned by today's standards. These days the standard algorithm text is CRLS ("Introduction to Algorithms" by Cormen, Leiserson, Rivest, and Stein). Sort of an "old testament" vs "new testament" difference, if that makes any sense.
Nice satire!
Writing is easy. Lots of people do it. Writing a Ph.D. dissertation is hard. Because details.
OP is being a bit flippant.
Conceptually, the idea of using alphanumberic characters to give computers instructions is "simple" and getting a computer to do basic operations is fairly simple with a good tutorial or guide.
The idea that the codebase for a web app like Yelp's website or a phone app like Snapchat is "simple" or "easy to learn" is of course patently ridiculous...I think it boils down to whether or not you give OP the benefit of the assumption.
Seriously OP really didn't say much other than, "No it is easy"
Thank you Dave Raggett
"you'll empress anybody"
I LOL'ed.
Vol. 1-3 were my bible during my early programming career and they, along with vol. 4, have an honored place on my bookshelf. I still refer to them to this day, 30 years after I got the first volumes.
Sometimes, real fast is almost as good as real-time.
The Art of Computer Programming is not a book to be simply read, but a book to be acted on requiring years of work to following the programming and thought problems therein.
I have sometimes compared those who have studied computer science (as opposed to learning how to program) with those who have studied music. You can be a very successful programmer without any computer science just as you can be a very successful musician without music theory. Mastery of the advanced studies of your discipline will make you a better than merely someone who can just get the job done.
This is a boring sig
in the series that Knuth would send you a check for $2.56. Was quite an honor - many framed checks, few cashed.
Old enough to lie, I think.
It's okay. This is why we have the Rust programming language, and it's Code of Conduct.
Kill all whites.
Step deeper into the world and you'll be truly amazed at how deep it is
Step deeper and it turns out to be deeper?
Wow, you're so deep.
> Programming isn't terribly complex. If you want to program, just do it.
You really, really should know better than that by now. In the 1980s, if you wanted to write a really crappy macro and use it on your computer, fine. Today, most software is exposed on the internet and runs on devices connected to networks that people depend on, networks that contain private information of one kind or another. "Don't worry about knowing what you're doing, just do whatever" is an extremely foolish approach.
wuut? complex is the opposite of the virtues you espouse.
The modern version is much more of a reference than textbook. While exercises still are part the book, it really for testing knowledge. Also, the field has just exploded and the task is really daunting. Satisfiability is an example, the current fascicle is 320 pages, but a more in depth look at the problem could run to twice that much and more. And there is new work being done on the topic every day.
Frankly, less and less programmers will need it, as it is easier and easier to create and use algorithmic libraries. Also, optimization just isn't what it used to be. Modern embedded silicon is quite roomy and complete control of the hardware leads to more problems (think buffer overflows) than it often solves. Finally, code that is verifiable is of more overall value, and so simpler algorithms and more constricted languages may be the future of a lot of code bases.
But, it's an awesome project and always will be.
I don't think I've read any college text book cover to cover. I open up TAOCP when I need to get into the theory on a particular topic.
“Common sense is not so common.” — Voltaire
But can you program in Z80 and 6502 machine code? You really only need to know a few instructions, because the details are in the bits.
Wish I had mod points.
Code, Hardware, stuff like that.
Side note: Knuth's books predated electronic publishing and were typeset, necessitating careful proofing of the galleys prior to publication and many months of delay between completion of the manuscript and actual publication of the book. The errors made by human typesetters weren't always caught, which led to bugs in the published book (and in some of the algorithms and code). Knuth offered a reward of $1.00 to anyone who was the first to find and report an error. No email then, so you had to write a letter or make an expensive long distance phone call. Knuth actually sent out hand-signed written checks, but not many people cashed them, preferring instead to display the signed check as proof that they had found an error in one of these volumes. If you were wondering about Knuth's inspiration for creating LaTEX, this note should help explain that.
Programming isn't terribly complex. If you want to program, just do it.
And people wonder why software is full of bugs and their devices crash or have hiccups.
Back when I was at AOL in Vienna, VA, there was a bookstore called Computer Literacy Bookstore, a few doors down from the headquarters of Ringling Brothers & Barnum & Bailey Circus (who annually would show off their elephant-de-jour).
I bought the first two editions there the moment I became aware of them. They're signed in pencil by Knuth himself. The fact that he used pencil I found amusing.
I bought the third edition, which was a huge, huge event as it was much anticipated, and enjoyed it better than the first two since I have rather poor mathematical ability and could relate more to the fuzzy concepts of sorting and searching than some of the more mathematical concepts in the earlier two editions.
Since I left the software engineering community in favor of what we used to call "systems programming" and now call "DevOps," I didn't become aware of the "4A" edition until this evening. Thanks for the heads-up. Maybe it will encourage me to get back into software engineering and overcome my weakness in math.
Kriston
Not mentioning efficient algorithms.
Slashdot, fix the reply notifications... You won't get away with it...
Those dumb names, like the silly "MongoDB," were just created to encourage the hyping of their technologies, even though they are simplified and inadequate versions of what was earlier well-tested and battle-proven.
Kriston
I did however read the Notepad help file.
yea, we have found the PHP developer!
Actually that was in their resume, but nobody at MS had the necessary CS level to ensure the candidate has read (and understood) the books.
Slashdot, fix the reply notifications... You won't get away with it...
If you're working for Oracle and coding the Oracle database and are looking for an algorithm to squeeze a bit more performance out of the engine, go ahead and buy the book, you might find something in there. But most programmers are using sets and dictionaries in their chosen programming language that has a decent implementation of algorithms and won't be helped by some algorithm which might squeeze a few more cycles out of the computer but nobody will reward you for. The Knuth book is for high fliers and hard core computer science projects, not for your average programmer.
I started reading them around 2001 and went through the three books, a little bit at a time. Went through most of the exercises with 30+ difficulty, but couldn't really solve all of them.
A lot changed to myself - back then, I was a newbie undergrad programmer with undergrad-level math skills. Fast forward 15 years, I went through grad school and then couple of years of industry experience. My main programming languages moved from C++/Java to VHDL, then moved on to SystemC and SystemVerilog, and back to C++ with a bunch of bash scripts.
So, did I get to use the knowledge that I gained from reading it? Not much, I didn't even have to write a single data structure or algorithm because there are perfectly good (or at least, good enough) libraries for most of the issues that I had to deal with. Neither did I have a good usage of the math courses I learned (remember things like Laplace transformation or L-U decomposition?), nor did most of the non-engineering courses I took helped much. Still, all of them helped shape myself on understanding the world and helped gaining problem-solving skills.
Would I recommend it to other people? Depends, if you find your data structure and algorithm textbook easy enough and you want more challenging stuff, TAOCP is a perfectly good motivator to train yourself to solve complex problems. However, I think there are other ways to train complex problem-solving - e.g., a lot of advanced math/physics textbooks. However, for people who tend to fall asleep once they see those weird characters (and would rather live with pseudo-assembly code) TAOCP is a much better solution.
If you want to learn practical programming skills, then don't bother reading.
Programming isn't terribly complex.
Awesome that you think so! Now, program some realtime flight surface control software for a fly-by-wire jet and sleep well knowing that your program will never, ever, kill anyone... (Or, substitute any other safety critical software you can think of - and theres a lot!)
"Programming" (by which I really mean software engineering) is one of the most complex activities in existence...
Galileo: "The Earth revolves around the Sun!"
Score: -1 100% Flamebait
"Real programmers don't use PASCAL!" http://web.mit.edu/humor/Compu... I picture 110010001000 toggling the OS into the front panel while the rest of us have already bootstrapped the machine with kixtart a month ago. It's ok to stand on the shoulders of giants, but at the same time, it's good to look down and see how the foundation is you're standing on is really laid. There are times in my storied career where I have actually benefitted debugging c# or ruby code because I understood how parsing and execution worked. I have written better database queries in 4GL by knowing what was happening on the metal. So, before you get overly dismissive of knowing soup to nuts, I'd say that you should be aware that YES you can get by without it. But knowing the whole shebang, all the way down to the machine code, at least in broad strokes, DOES help you out occasionally, if not all the time.
Speak for yourself.
“Computer Science is no more about computers than astronomy is about telescopes.” - commonly attributed to Edsger Dijkstra, but disputed.
[...] Mastery of the advanced studies of your discipline will make you a better than merely someone who can just get the job done.
The caveat being here that a good portion of what goes for CS at universities is essentially "How to use the vast resources of a supercluster as a glorified pocket calculator". I had the dubious honour of suffering through four semesters of so-called CS at my uni, and I can attest that you can be an incredible computer scientist and still be unable to program even modestly simple applications. And that is said without even touching upon the vast difference between CS and software engineering (and the equally vast difference between software engineering and programming, to be fair).
All three disciplines have their place. But CS is not exactly the 'advanced study' of programming.
Rudolf Hess edited Mein Kampf. He was the very first grammar nazi.
I can program in 6502, Z80, x86 and 680x0 assembly languages. Knuth doesn't deserve any thanks.
Me too. Rodney Zaks gets my thanks.
I use TAOCP as a handy authoritative reference for algorithms in specs. It's not a great read though.
I should use this sig to advertise my book ISBN-13 : 978-1501515132.
But can you program in Z80 and 6502 machine code? You really only need to know a few instructions, because the details are in the bits.
I wrote my own assembler and debugger for programming my Apple //e. I got fed up of typing in hex.
https://github.com/dj-on-githu...
I should use this sig to advertise my book ISBN-13 : 978-1501515132.
>rich base classes
are complex.
Machine code is simple. There's much less to know,
I should use this sig to advertise my book ISBN-13 : 978-1501515132.
And You should as well. It would give you the right knowledge to understand the whys and the hows.
Sent as ripples into the electromagnetic field. No single photon has been harmed in the process.
NASCAR is easier than, say, driving in Amsterdam. In Amsterdam you find bikes and pedestrians on your path, and, Oh! The horror! Right turns!
-- Cheers!
Programming isn't terribly complex.
Awesome that you think so! Now, program some realtime flight surface control software for a fly-by-wire jet and sleep well knowing that your program will never, ever, kill anyone... (Or, substitute any other safety critical software you can think of - and theres a lot!)
"Programming" (by which I really mean software engineering) is one of the most complex activities in existence...
Just because it can be doesn't mean that it always is. The avionics-software programmer is working very differently to the muh-first-website programmer. It can be complex like avionics, but it can also be simple like javascript text-adventures.
"Programming" can be, at times, one of the most complex activities in existence. It can also be, at other times, one of the simplest activities you can find paying high salaries. Lets not pretend that programming is always more complex than brain surgery. It can (on rare occasions) be, but it's usually not much more complex than arithmetic.
I'm a minority race. Save your vitriol for white people.
Do you see the connection here? CS is not a degree in programming and it should not be a degree in programming. I don't expect a trained CS to be a good programmer. I do expect one to be a good mathematician. I expect one to model information requirements and computational systems as mathematical objects and then be able to formally prove certain properties about it.
I only see him about once a year. He's still a sharp cookie.
His 22nd annual Xmas Computer Musings Lecture will be Dec 8th (auditorium seating is rarer than unobtamium for a talk by Dr. Knuth, but it is web-streamed).
Mastery of the advanced studies of your discipline will make you a better than merely someone who can just get the job done.
OK, genius. Perhaps mastery of the English language would make you a better.
Creative writing requires creativity. Programming does not. Once upon a time if you came up with a brilliant idea you would have to code it yourself and that gave rise to the cherished myth of the computer genius, but thankfully we moved on from those primitive times. Now there are designers, who are creative, and programmers, who are code monkeys.
As surveys go, it would be as good as most of the recent ones.
Anyway, I've never read even one volume of the series, though I'm pretty sure I consulted it at various times. It was certainly available in the university libraries where I was teaching or studying. Also I remember seeing it in the research library when I was supporting the researchers. However, I can't really remember any details after all these years. The place I should have been introduced to it was when I was earning my CS degree, but I don't think I even knew about it until afterwards... At that time I think I primarily associated Knuth with TeX.
According to my records, the only Knuth book I've read in it's entirety was Surreal Numbers , but I'm suspicious of my memories of that book... Did he construct an entire number system starting from the empty set? Was it based on a lunchtime conversation he had with a pure mathematician, and he basically reconstructed the discussion at book length?
Freedom = (Meaningful - Coerced) Choice != (Speech | Beer^2), and sad sock puppets' bad mods avail them naught.
You do not know much about MS do you?
https://en.wikipedia.org/wiki/...
He *might* know a thing or two about writing OS's.
It's a book to be used as a reference when you need some depth in a particular subject. I refer to "semi numeric algorithms" quite often as an enginner implementing DSP. Kudos if you have read and understood the whole 4 tomes, but that was not the way Knuth is expecting one to use his book.
Have not read the books.. But why not just use platforms such as LiveBlox instead of spending a lot of time and effort to learn to program?
I've only skimmed TAOCP, but I feel like the mystique around it has more to do with its historical significance than being a real learning resource.
You wouldn't pick up learning physics from Newton's Principia (Feynman's Lectures on Physics might be a better start) but it could be worth reading to gain an appreciation for the process of discovery. For TAOCP, perhaps a newfound appreciation for typesetting.
That's not a name I see often! That's how I learned assembly too. "Programming the Z80".
Bullshit. Surgery is complex. Aerospace engineering is complex. Programming is not. You deal with a controlled environment and you can backstep at any time. If you can't, it's your fault. Cooking is far more complex. There are good reasons why programmers are being replaced by low-wage workers while chefs are not.
Hahahaha, funny! Sorry, do not have mod-points, but this is sarcasm done extremely well!
Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
It's not like a novel you read front to back. If you need an algorithm you look it up.
I had to write a math library for a DSP that didn't have compiler support yet. TAOCP came in handy then. The parts I did read I went over again and again and once again. It wasn't fun by any means.
Interestingly, despite being in CS for now 30 years and doing some quite algorithm-intensive and complicated work even today, the only time I consulted them was for an exercise in CS 101 that referenced something in there. I have always found easier to read and better references, quite a few of them research papers. Don't get me wrong: I think it is good that they exist, but they are more a reference for fundamental research than a handbook for an engineer or applied scientist.
Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
Every program written today is in way shape or form another program from an earlier age with one more level indirection. There is a saying in the K&R world, that there is no problem that cannot be further simplified than with one more level of indirection. The difference today is that we no longer want to choose that level of indirection. We want to have it given to us. What was once syntactic sugar has become semantic necessity through reward for the deeper understanding of the subject. Being faster to market wins over being better.
"Because " is not a complete thought. Could you please expound for those of us that don't think a noun covers the gamut of possibilities that you wish to cover? Since we are all geeks here, it stands to reason that the universe of the set covered by "details" is larger than your intent and indicating that your intent is universal assumes we have the same level of understanding as you.
"Because <noun>" is catchy in journalism because "for news - it shows an all encompassing view to attract audiences." (See what I did there?)
I for one would like to know what details you mean. Please and thank you.
I took CS. I was required to program algorithms and do proofs in a multitude of languages. And none of the languages used were taught. The basis was trial by fire. Computer scientists were supposed to be able to learn any language at any time in order to solve the problem at hand. We learned to be language agnostic and pick up the language required every 2 weeks. It worked.
Nah, not really. It just requires logical thought.
Seems unlikely you'd find it as easy as you claim then!
SJW n. One who posts facts.
I never read TAOCP properly, doing all the exercises, following all the proofs, etc. But I very often use it as a reference - especially when I need to make a *hardware* implementation of an algorithm.
I have the first three, and I have read parts of all of them. Especially "Sorting and Searching".
It's reference material. You read it when you need it to get a much (much) better understanding of what you need to do to solve a problem. That's the point of reference material -- you don't have to read it except for the parts you need. That leaves your brain free to think of important things, like where you left your coffee cup.
good reasons why programmers are being replaced by low-wage workers while chefs are not.
Yup. Because you can't outsource a chef to the lowest salaried third world country just to save a few bucks.
Believe me, with the razor thin margins in the restaurant industry most bosses would outsource to the third world if they could. To hell with the food quality, everyone else outsourced too!
In fact, I keep re-reading parts just for the imaginative spark.
OK, I admit to being an assembly language addict. I think describing tasks in machine language is as stimulating as a book full of logic puzzles. (But let me still recommend ANY book by Raymond Smullyan, such as, "The Lady or the Tiger?" https://www.amazon.com/Lady-Ti... )
I also admit to programing in LISP and using Jan Lukasiewicz's notation for symbolic logic.
I suppose you should keep these things in mind while evaluating my recommendations.
"The mind works quicker than you think!"
These are books about algorithms. I've read them all, and worked the problems.
At the risk of exposing myself as an elitist snob, I wonder about the people who don't think one has to understand the basis of an algorithm, and what makes for an algorithm as opposed to a heuristic.
Decades of research went into understanding how computing machinery accomplished the things that they did. A certain Bill Gates came along and decided none of that highbrow stuff applied to the new paradigm of PC's. That's one of the reasons that we had fifteen years of the worst memory manager on Earth, in Windows. In point of fact Knuth talked in detail about this memory management as a counterexample of how it should not be done. But it was simple amd worked on PC's and hey, memory is cheap.
Knuth's books are about the Fundamentals. They're not practical guides and they never were practical guides. They are insight into how a certain variety of stochastic machine operates and the kind of things one must think about to design proper algorithms that work all the time, as opposed to work most of the time. They are the Zen of computer programming, a philosophy of thought and a discipline for creating algorithms. This is not how to write code.
It certainly isn't for people who confuse how to speak a language with how to converse.
Don't take life too seriously; it isn't permanent.
No one is going to read the whole thing, there's no reason to. You only read the parts that you need to work on. Some of the material doesn't exist outside the book and is referenced by other works. It's a true compendium of computer science and you can't call yourself a serious programmer without keeping a copy nearby that you can flick through. Think of its as an extremely well written encyclopaedia. I just ordered a physical copy since I was working off scans. It's on sale on Amazon, don't hesitate to buy it if you have the room for it.
That's mostly true. In C, C++ (probably others), you used to build your structures knowing how the
processor would access them from what the compiler produced. Now, the compiler can re-order your
structure, put parts of it in its register set, and so on (depending on how the struct is used). So, it is
helpful to understand the low level stuff; I've come to trust compilers to do as good, if not better of a
job than I can arranging those items for optimum performance.
CAL === 'unaided'
I imagine that's something like how constructing buildings (architecture) relies on engineering, and often it helps to know why a column has to be where it is, and what other possibilities there may be, to support the floor in some other way, but most of what the architect does is actually planning the layouts and elevations and how the building relates to the site and the people and their activities.
So I would imagine that a lot of the "discipline" in large projects isn't so much about pure engineering, it is often more about organising parts into systems which can be developed over time.
Like how the architect knows that where they put the hotel restaurant is going to affect where the kitchen goes and therefore where the store room goes and hence where the service entrance will likely be, and that you don't want to end up having to tear up the plan and start again because you've ended up with the service entrance being located right next to the main entrance.
If an abstraction is clean, and has zero leakage then it is fine to not understand what it is hiding. I don't know of any such things in CS, but sure in theory it would work.
Slashdot: where don knuth is an idiot because he cant grasp the awesome power of php
Funny, only the other day I was reading an article on how a michelin star famous restaurant was paying chefs less than legal minimum wage. Meanwhile all the subpar programmers I know are earning above median wage. Perhaps some shill accounts on here are trying to drive down wage expectations for knowledge workers, do you think?
It's terribly difficult to empress someone. There are claims of royal lineage to sort out, golden carriages to arrange, diamond tiaras and suchlike.
Yes, my UID fits in an unsigned short. So?
It does not.
CLI paste? paste.pr0.tips!
Oops, actually, it does. Never mind, I was thinking the smallest allowed range of unsigned short was [0,255].
CLI paste? paste.pr0.tips!
I used to. When the only tool you have is a sector editor, all your problems are solved with 21, 00, 00
“Computer Science is no more about computers than astronomy is about telescopes.” - commonly attributed to Edsger Dijkstra, but disputed.
[...] Mastery of the advanced studies of your discipline will make you a better than merely someone who can just get the job done.
The caveat being here that a good portion of what goes for CS at universities is essentially "How to use the vast resources of a supercluster as a glorified pocket calculator". I had the dubious honour of suffering through four semesters of so-called CS at my uni, and I can attest that you can be an incredible computer scientist and still be unable to program even modestly simple applications. And that is said without even touching upon the vast difference between CS and software engineering (and the equally vast difference between software engineering and programming, to be fair).
All three disciplines have their place. But CS is not exactly the 'advanced study' of programming.
I went through 4 years of computer engineering, some classes were shared with the CS students and some were CE specific. I found that the CE classes seemed to do a better job on focusing on making something and forcing us to learn the theory on our own so we could make that thing. In any of the shared classes the CS students were great in tests but struggled in projects, while the CE students rarely had trouble. The CS students were just as smart but I don't think the focus on theory, rather than application, handicapped them.
I've gone back for advanced degrees in CS after working in development for a few years and the theory courses make more sense as I have the background to see how they could be applied. I really wish colleges would focus more on practical work, rather than theory. Though I have noticed somewhat of a shift in that direction over the past 15 years.
I like TAOCP, a lot; mainly, because the material is so coherent, precise, well justified, and understandable enough. I spent many weeks reading sections of TAOCP; especially volume 2, on Semi-numerical algorithms; my copy has several post-it marks on techniques useful in my field (applied cryptography): wide multiplication algorithms, modular arithmetic including exponentiation, statistical tests.
I also had significant uses of volume 1 (Fundamental Algorithm), which covers things such a tree, and hash tables; even purchasing the third edition, on top of the second.
That said,
- _reading_ TAOCP from start to end is not something to consider lightly; perhaps if one has a year to spend.
- I never caught on the use of MIX in some programs; I just skip this, and advise contemporary readers to do so, even if that's missing a part of the beauty.
I agree; anyone can program, with no special effort required.
Programming so you deliver working and maintainable code on time and to budget, on the other hand...
Quidnam Latine loqui modo coepi?
As many above have pointed out, there is little reason to read the entire series "like a novel" from cover to cover, in addition to the fact that yeah, it would take a while to WORK through it like a textbook as opposed to read through it quickly to see what is there. And yeah, there are better books now in profusion on many of the topics covered, although AFAIK there is no book or book series that is as encyclopedic on the subjects he covers.
However, many people will find some of the sections very useful. I personally found "Seminumerical Algorithms" useful indeed when learning about random number generators and testing random number generators. It isn't the last word, and it certainly isn't the latest word as we move into a 64 bit world and beyond, but it is an excellent starting point. In other parts of the series there are other gems or nuggets well worth studying or reading, even if you move on to actual research papers or better books afterwards.
To sum up, it is a useful thing to own if you are doing a lot of very widely spread code development and need to acquire literacy quickly in subjects it covers, even if you are going to end up looking for an O'Reilly text on some of those subjects to get a more modern perspective. Those OR books are probably going to reference, rewrite, and augment Knuth.
Note well that I'm an Old Guy (tm) and actually did write a lot of code in Fortran once in the long ago before abandoning it for C and Unix and beyond. TAOCP was one of the ONLY really good encyclopedic references for people who were NOT CPS majors and who needed to learn about algorithms of one sort or another or some aspect of coding covered in one of the many CPS courses they never took. They (I) didn't need a course with the best textbook of the day -- we needed to get started. Once started, we knew how to learn and go beyond the start. 1.5 cubic feet of shelf space wasn't too high a price to be able to learn something about everything or anything to get started.
Even when the experts all agree, they may well be mistaken. --- Bertrand Russell.
In college at UCSD, about 1978, we not only read these books we used the assembly language to write real functional programs, run on the mainframe, on which we were graded.
The professor once got himself into a corner trying to give an example using the language, and after several attempts to correct it on the fly on the chalk board (yes, real chalk) he made it a homework assignment due the following week.
Are these worthwhile books? I'd say yes. Using them as reading and actual homework made everyone in the class sharper when we moved on to the real world jobs after college. You knew and understood the basics, and since you knew how the algorithm ran at a fundamental level, you knew how to write tighter code.
Using books as a list of algorithm references- sure why not.
Studying these books line by line is a monumental effort which is hard to justify, if the only thing you are after is coding.
I got all of them. Yay! And they are all mostly good. It's fun to know what algorithms exist out there for a problem, it's fun to know why something is good or not. The abstract part is awesome. And it helps hone your instincts whether somehting makes sense or not by having good litterature in your subconscious mind.
But then, the algorithms are incredibly generic. They are also complex, but generic. These are "solved" problems, with a really great academic solution, that might or might not apply to your day-to-day life. And usually, someone took the time to make such algorithm and improve upon it by multiple optimizations related to day-to-day operations instead of a conceptual idea.
These books algorithms don't (all) dwell in modern optimizations, multithreading, multitasking, pipelining, locking. They don't answer questions people have on a particular nitpick they might have. But they do help give a generic and very potent algorithm for you to start looking upon, all of this in beautiful books. And like all education-based books, alas, the most complex of issues are "left to the reader". Yeah, that's the most complex of topic (the one you're looking for) and they just say oh yeah, have fun. I hate that crap.
Now, today, we have libraries and libraries and libraries, open source this and that, online papers for the latest greatest, stackoverflow for day-to-day. And there are specialized books for specialized topics. I once bought a book that answered all the most complex questions with C implementation. That included creating a B-Tree (which is usually left as an exercise after explaining the concept). Now I am the proud owner of a Leaf-data B* Tree I created myself. That wasn't brushed adequately at all in Knuth books. Another book took a hundred pages to explain all the intricacies of userland/kernel/vm/chipset memory management, and due to some time I had to take working with a horrendously subpar slowpoke error-prone memory algorithm on an embedded device with 64MiB of RAM, I wrote my own alloc library with exactly the requirements I was looking for (mostly a multilevel buddy system with 4-byte header per block and 2K of data header alongside an embedded headerless bucket allocator for tunable =16 bytes allocations with O(1) operations 99.9% of the time and the .1% being not thread-locked and very short). That's not starting to be brushed at all in a general compendium of algorithms.
So are they relevant? I haven't even looked at them for the past 5-6 years I'd say. But they gave me what they had to give: insight on complex problems and ideas for solutions if I ever had to go there. No need to understand every single proof line. I am just glad I grew up with them.
I read the first three in their original incarnation.- the two that had the deepest impact were Semi-Numerical Algorithms and Sorting and Searching.
The code in pseudo-assembler wasn't easy to read, but I coped. I believe he completely reworked that in the new versions of the first three books before starting on volume 4.
I haven't read the new versions, but I'd recommend them over the originals to a newcomer.
Real programming happens in your head or on a white-board with pseudo-code. Pseudo-code writes exactly the same today as it did 100 years ago, one logical step at a time. If Knuth has made pseudo-code easier to write, then I will agree with you, that he made programming easier.
Step deeper into the world and you'll be truly amazed at how deep it is ... and likely staggered that it works as well as it does.
You make it sound like some mystical complex thing. I do think that it is amazing how far computer have come, but I refuse to believe that logic, the cornerstone of programming, is some " deep and mystical" thing. The only thing I am surprised at is how difficult logic is for most programmers and how the state of programming isn't worse than it is.
Don't feel bad. These things build (unsigned) char-acter. Of course, that's still assuming your architecture has eight bits per byte. -PCP
I have the books in question on my bookshelf. I can't say that I've worked through them, but I have used them for reference more than a few times through out my career though. I usually end up using them if I need to know the little details on an algorithm, it's not that often, but they are a real life saver when you really do need the detail.
But the first three (all I have read) are excellent. Yes, it takes time to work through. But it is worth it. Knowing what has gone before helps in figuring out answers to new problems. Knowing whether something is a new problem saves a lot of time.
I keep meaning to jump back in and catch up.
Of course.
And I won't be sending any resumes to Microsoft, that's for sure.
The interview went well, several managers in the company wanted to hire him and the choice was his. He choose my group. He quickly showed himself as a superstar.
After he had been on-board for a while he asked if I knew why he choose me. It was because I had 3 volumes of Knuth and 6 volumes of the computer programming series on my bookshelf.
I was embarrassed to admit that I hadn't read them, he said it didn't matter, I had them and that said all he needed to know.
After that I started Knuth but didn't last long.
I'm no longer there but last I heard he was in middle management. Smart guy.
If you have as CS degree and are not familiar with Kuth you should ask for a refund from your school.
Like the majority of my college textbooks, the bookmark in the first volume is at page 20.
I really, really will get back to it sometime. Honest!
Now that I've retired I have better uses for my oh-so-valuable time.
Catching up on 'Mythbusters'.
Throwing out 30 years of junk we have acquired.
Frequent naps.
And my all time favorite: sitting around and doing nothing other than listening to my arteries harden.
It's convincing a review panel that it is valid is hard.
I read V1 and figured out that I'd re-invented a bunch of fundamental searching and sorting algorithms like hashing and trees. Sigh.
V2 and V3, I just skimmed and cherry picked for help with specific problems.
I don't have V4 and 1-3 mostly gather dust these days.
The books are somewhat dated a checkpoint in time of the state of computer algorithms.
They don't contain later discoveries like B-trees or red-black trees.
For someone with an understanding of under the hood computing, they shouldn't be especially hard to read.
Preventing re-invention makes reading a compendium of algorithms for the areas you work in necessary.
These were well done in their day, but seems there should be a more up to date these days?
Only a person who didn't understand programming would make such a ridiculous statement.
Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
Nah, I've been programming longer than Knuth has, starting with machine language. You just need to think procedurally.
That's a major challenge for most people and the more abstract the procedure the more challenging. A lot of us here "just get it" because our brains are wired that way, if your brain isn't wired that way it's extremely difficult to learn.
Apocalypse Cancelled, Sorry, No Ticket Refunds
It isn't terribly complex now that geniuses like Knuth have spent literally decades simplifying it for you, sure. Step deeper into the world and you'll be truly amazed at how deep it is ... and likely staggered that it works as well as it does.
I've spent a good chunk of my career performing optimization of code using these types of principles and I hate to say this but we now live in a world where this knowledge is limited in its application. You have several movements most notably the cloud movement where when you have a performance problem you just spin up more VM's and scale them. On a side note, that's more financially beneficial for cloud providers but we'll leave that for another discussion. Up until about 10-15 years ago, hardware was very limited and you had to make good use of it to get scalability. The next one that's happened over the past 15 years is the wide adoption of "even more higher level languages". Remember when C used to be considered a much higher level language because assembly language was so tedious? Well guess what we have now. We have languages like java running inside of code compiled in C++ which then compiles your java code down into byte code which can directly translate to assembly language. What does this mean? It means that we are now far more removed from access to the metal to even do a lot of the optimizations that we've done in the past. With all these layers of languages you have other problems where compiler/interpreter optimization occurs in different places and that you don't have access to enough of the metal to be able to do adequate optimization anyway.
I don't mean to sound like I claim that attention to optimization is misplaced today. What I'm saying is that the old methods of optimization such as those described in this book that I learned in Computer Science, are not really applicable to programming today. The concepts are sort of useful. If you can understand the mindset required to do effective optimization you can still find creative ways to apply it in today's technology, but it doesn't directly translate. What I do find interesting is that when I look at what we had to do in ye olden days I realize it's a lot less frustrating to be a programmer today than it was 30 years ago.
We'll make great pets
He hasn't even started volume 7 on APPing APPs in APPOS 10.
Dude, NASCAR, you turn left, over and over ...
Apocalypse Cancelled, Sorry, No Ticket Refunds
Have You Read 'The Art of Computer Programming'?
Once, when I was in grad school, and I kept plowing through them for a year or two after I left. I still have them somewhere in the attic. I wouldn't do it again, but I would recommend any one in CS to give it a shot. It is a good exercise (just as it is a good exercise to try at least some parts of MIT's SICP.
I wouldn't use them as a reference, though. For that, I hit CLRS, Algorithms by Sedgewick or O'Reilly's Algorithms in a Nutshell.
TAOP will make you a programming demigod as much as reading The Art of War will make you a warlord.
Open Source Network Inventory for the masses! Kuwaiba
I don't question this, but I wonder how you manage to keep the skill. I used to program Z80 assembly in the late 90s (Sharp organizers) and 8086 in the early 90s, but I can't say that I know Z80 and 8086 assembler anymore.
Or have you managed to keep up the memory by continuing to program antique devices (not a terrible idea)?
Programming isn't terribly complex.
Awesome that you think so! Now, program some realtime flight surface control software for a fly-by-wire jet and sleep well knowing that your program will never, ever, kill anyone... (Or, substitute any other safety critical software you can think of - and theres a lot!)
"Programming" (by which I really mean software engineering) is one of the most complex activities in existence...
Just don't cross the International date line east to west
Apocalypse Cancelled, Sorry, No Ticket Refunds
Really? I remember covering recursion for maybe 1-2 weeks and have been using it off and on for a couple decades. It's not complicated, just different, like almost every other aspect of programming. Head, tail, combinations of both - it's all basically the same logic as you would see in a loop, just organized differently. Some solutions are easier to express recursively. And if they're not, don't use recursion.
--- Most topics have many sides worth arguing, allow me to take one opposite you.
I've read the 3 initial volumes, and they remain a useful reference. I don't need to look there often, but when I do, TAOCP is the best reference I own.
I don't pretend to have read every word, of course. Some of the stuff on random numbers is only of mild interest, I don't really care about tape sorting, etc. I've skimmed nearly all of it, and read maybe 1/4 to 1/3 of the text in detail.
I've not yet ventured into Volume 4, although I think I'll want to do that sometime reasonably soon.
One of the most important things is knowing when you don't know enough.
TAoCP is a never-fail personal Dunning–Kruger removal tool.
I never finished the mathematics degree I once started, but I always found the larger concepts easy enough to understand when sitting beside a real mathematician.
I certainly would have difficulty completing most of the HM exercises (this despite also owning Concrete Math). I rarely have difficulty understanding the form of the solution if I cheat and look it up.
Another book I'd put into the same category, roughly, was the original Applied Cryptography where it ought to be far more obvious that one shouldn't naively roll one's own, but somehow, for too many DK-impervious DK-permeable programmers out there, it isn't. (I'm looking at you, Wi-Fi Alliance; and every idiot who ever used the speedy MD5 to hash a password database, with or without salt, or worse.)
There's little wrong with Knuth's exposition that actual competence wouldn't fix.
You do the math.
PHP's ease of use and widespread popularity has certainly allowed for the creation of some very hideous abominations. However, PHP itself doesn't deserve the rapp that was brought on by the "know enough to be dangerous" wannabe programmers.
He has nothing to teach us. He should just go hide under a rock and let us new and intelligent software designers take over!
Probably better for you to pass on the whole online "socializing" thing.
The GP may mean that it's difficult (complex) to write noncomplex, but good code.
It's pretty clear apk hasnt read many books on computer programming or anything else for that matter.
I read the three volumes in college. I was a chemistry major, so this was all my own doing. I had built an eight bit computer in high school, a SWTPC 6800 machine. During college I became an assistant sysadmin on a DEC system- 10 minicomputer in one of the chemistry professor's lab. I still have to this day a deep interest in both chemistry and computers. These three volumes were the basis of my informal computer science education. (My formal education resulted in a Ph.D. in Physical Chemistry.) I was especially intrigued by the sorting algorithms and coded several of them in different languages for comparison of their operation.
The books are a fine examples of mathematical typography and I became an early adopter of Knuth's typography software TeX and Lamporte's LaTeX. I was the first person in the UIUC chemistry department to digitally typeset their dissertation and print it on the department's laser printer attached the the VAX-780. I investigated WEB (the self documenting language that TeX is written in) as a possibly useful programming tool, but found it to be much too cumbersome.
Others in this thread have commented on how miserly the algorithms are in their use of bits. The powerful processors and gigabytes of RAM available in desktop computers and even some portable devices can lead to bloated and sometimes inefficient programs. With the increasing tide of IoT devices with limited computational resource and available power, a miserly mindset can lead to more functional programs and better battery life. Even GPU programming lends itself to being miserly in the use of resources.
This set of books is not something to read to learn how to program. These are the volumes you read to become a craftsman and more than just competent at programming.
This explains the mountains of shot software design we're dealing with today. Those 'designers' are just as moronic as their code 'monkey' counterparts.
I read all of the available volumes (1, 2, 3, 4a) in my University's library.
The first thing that I noticed about them was that they were nearly unused despite some of them being there for several decades.
Now we should distinguish between reading, understanding and working through the exercises.
I had little time while reading them so I could not get everything to 100%.
I would say that I understood about 3/4 of what I read and that I actually did less then 1% of the exercises but I worked through the solutions of about 10% to understand what it takes.
If I had more time, I would go back and work through more of them on my own in the language of my choice.
Now what has reading this books done to me?
Well, the itching got worse but on the plus side I would say that they gave me a broader understanding of CS.
Although I began reading them about five years ago, I have been using concepts that I first learned from those books about twice a year.
I reread some parts of them for reference several times and I think this will continue.
I feel that a modernization might be a good thing to do, although I cannot imagine a person that has the knowledge and endurance of DEK *and* still has free time for that.
$60 for the Kindle edition? It's hard enough to slog through without having the nagging feeling you're being milked.
Mission: To provide products that consume time and energy as entertainingly as permitted by the laws of thermodynamics.
I read 1/2 of volume 1. The remainder is on my bookshelf. I have used snippets to help in my studies. I found an example in the combinatorial volume that helped me on an assignment in my algorithms course. The Internet was completely useless, TAOCP captured the knowledge succinctly.
It goes to show that well prepared books are still beating the Internet for knowledge archiving (although, Google scholar may have extracted the passages, I still admire the work Knuth accomplished here. An incredible feat and a wonderful person. Huge fan.)
It's hugely useful for that. You can read it in snippets. Reading it as if it were a novel would be about as smart as reading a dictionary that way--not necessarily a terrible use of time, but more of a slog than the average geek is going to be able to manage.
I found the first 3 volumes far too abstruse to be useful - or perhaps "to be practical" would be the better phrase. I don't think that the concerns of the modern software design team are well handled in it. It's kinda the War and Peace of the CS world - you definitely want the (5) volumes on the bookshelf in back of you for your resume/PR photo, but as far as reading it? Not so much. I think it's more to be recommended for historians of CS --although there are plenty of comments from those who claim to be using it. The range of jobs and educational backgrounds are so broad, I don't think there's any one neat answer to the question.
You're just nybbling away at the parent's ego now.
I've fallen off your lawn, and I can't get up.
Its irrelevant these days, since commercial programming is no longer an art.
Programming used to be an art. Art implies using innate skill to create something intrisically elegant/beautiful and mostly intended to be around for a while. Since this book was written, most institutions have done all they can to remove all creativity from programming, turn it into a braindead dumbed down repeatable process so companies can get away with hiring even the cheapest most clueless people to write software. Ive seen time and time again that there is no reward or recognition for writing elegant, stable code.
All the rewards/recognition goes to those who bodge together a quick unstable hack not suitable to be maintained or to last longer than the 10 minutes required to convince the boss to check the "done" box. They move on after blowing their own trumpet and leaving a "TODO: rewrite this" comment for other more careful people to find and repair their damage. But the managers don't see that part.
Yes. But more importantly, I can program in 6809 machine code. Including building all the index modes. Which, back in the day, is one of the things that saved me from having to design in, and then program, CPUs like the 6502 and z80, both of which are seriously anemic by comparison. But I prefer to program in assembler. Because I'm sane.
My affection for the 6809 ran so deep that I wrote the 6809 emulator you'll find here, which required me to implement the entire instruction set from the ground up.
But yeah, I can write machine code for about 10 microprocessors. And you know what? In the day... that was useful. I could read (E)(P)ROM dumps, I could cold-patch... but today, I just wish I could get the brain cells back. :)
I've fallen off your lawn, and I can't get up.
Well... no, it means that you are, perhaps. Some of us still write in c or c++, and keep our attention on the details. You can tell you've run into one of us when the many-functioned app you get is a couple megabytes instead of 50, runs faster than the fat ones, and doesn't suffer from black-box bugs inherited from OPC.
I always thought that the user's CPU cycles and memory were things a developer was obligated to treat as the user's valued resource, and so not things to waste.
I know, totally out of date thinking. It's ok, I'm old, I'll die soon. :)
I've fallen off your lawn, and I can't get up.
Not necessarily. For one, you should make the code readable by a typical developer, not an ideal developer. You cannot control all future staff. That means you have to try to think like a typical developer, not an ideal developer, and that may exclude ideas that are "logical" to you.
Second, having a feel for how things tend to change over time helps one design code that is better able to handle future changes (fewest code changes and disruptions). That often requires experience in both coding and the domain at hand, and a feel for how and when fickle managers/customers change their minds.
That's not direct logic, per se, but a combination of general experience, domain experience, and experience in human nature.
I wish it were merely about logic. Life would be easier, especially for us nerds who tend to have sub-par people skills.
Table-ized A.I.
My preferred book is: https://www8.cs.umu.se/kurser/...
I basically bought it because it is a superb hand craft (I mean cover, paper and print).
The contents is an easy read. When I bought it, it was the most expensive book I ever bought ...
To sad that the announced second volume never was published.
Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
This.
In fact several of the earlier classes (algorithms and data structures) were taught in a non-existent language, which looked vaguely like Pascal and we did the assignments in PL/I. In the scheduling and simulations class we had assignments in three different languages (GPSS, Simscript and Simula). We taught ourselves PDP-11 assembler for the minicomputers class. (Later I taught myself PDP-8 binary machine language so I could hack an RJE station controller on campus. Also APL to go beyond the canned functions for the statistics class.) And so on.
I have the first three volumes of TAOCP, and I've skimmed them and used them for reference, but not lately. I think for the last decade they just help anchor one end of a bookshelf.
As for astronomy and telescopes -- in fact in my astronomy & astrophysics course we spent a week or so on telescopes, so we'd understand things like diffraction limitations and so on. In my microbiology class we spent some time on microscopes. You can't do good science without understanding the limitations of your tools. But no, they're not about telescopes or microscopes or computers.
I still have Volumes 1, 2 and 3...gathering dust.
I first started programming in 1962, on IBM 1401 (dearly loved it's variable-length memory management) and IBM 704 (briefly, before it was replaced with a 709, then the 7090). I used to take a massive printout of the IBSYS operating system for the latter to understand how real people wrote code to achieve an outcome; that was back when programmers still felt it was essential to write comments to explain what/why that specific code was there, and its' purpose). At the same time, I was a junior member of a group of "code sharers" at C-E-I-R; we evolved a punched-card deck for the IBM 1401 that became the basis of every program we subsequently wrote (I ran into the deck, called "CELIB"--for CEIR Library--several years later in a consulting gig in Australia, where they'd been using it for more than a decade after originally getting as part of a contract delivery...which my name in some of the comments). I was also engaged in running huge "linear programming" models on the 7090, such as one that forecast the likely economic consequences to the U.S. of removing the tobacco industry (i.e., abolishing the manufacture and sale of products), but the code was written by my more mathemathically endowed superiors, Eli Hellerman and William Orchard-Hays and you may know it as LP90, which was posted to the SHARE library at IBM; I just wrote some utilities.).
So, by the time Knuth published, I was an experienced programmer, and I devoured his books with interest. Like many programmers and professionals in allied fields, there were lessons to glean (like, "Wow, that's clever," or "Hmm, that's an interesting way to look at that problem"). I'm sure they influenced me, but it was not a "cookbook" to me. After I read them, they went on a shelf, and moved from home to home, and they still reside in a prominent place on my bookshelf, but gathering dust.
Programmers, today (especially those under 35 years of age) seem to eschew the idea that anybody else's code could be educational, and I find that an odd and juvenile approach to the world. We must stand on the shoulders of giants, and I still, to this day, learn new techniques and insights (and folly) in others' code. But, I got here (now aged 75, and still writing the odd bit of code; even CMD language) by learning from others, for no ONE of knows as much as ALL of us.
Driving a car isn't hard millions do it.
I've waited until I was 37-years-old to learn how to drive. My father wasn't going to teach me as a teenager to drive stick on his one-ton flatbed that he put a million miles on in ten years. Since Silicon Valley has a well-developed transit system, I got around just fine without having a need for a vehicle. One day my father abandoned his old car in my carport. I had not choice but to get my driver license and take possession of the car. Took me three years to find out about all the repairs that he didn't tell me about. It's easier to own a car when you're more mature and financially responsible, especially if your father is DIYer who doesn't believe in mechanics.
I'm calling BS on Silicon Valley having a well-developed transit system. You may be confusing SV for SF. VTA transit routes (e.g., the transit agency responsible for mess that is silicon valley) have decided that the only viable transit corridors/routes are south san jose to downtown san jose and mountain view to cisco (aka north-sanjose). Ever other place gets fragmented bus service with no-transfers (I guess if you are a monthly pass owner you don't care about cost of transfers). With the current frequency, each transfer can cost you 15-20 minutes, it can take hours to get to where you are going. Local companies have pretty much given up on VTA and fund their own shuttles to Caltrain for the last mile, but that doesn't fix the "first-mile" issue (getting from your apartment to Caltrain or light-rail).
For example, in my old place, I tried to commute by bus for a couple weeks when my car was in the shop. Luckily I lived only 3 blocks from the nearest bus service, but that's because that bus winded through neighborhoods to get to the Great America transit area (where lots of bus lines intersect/terminate) just to get another bus to my job in Santa Clara (in the heart of Silicon valley) which terminated in a walk of about 15 minutes to my office. Total transit time by bus during commute time 1.3 hours vs average time in car 20 minutes. Needless to say, after 2 days, decided to rent a car. I used to also used leave my car at the office and got to SJC airport for weekend trips. The office to SJC (which is 10 minutes by car) required a 10-min walk, two buses to eventually get to Santa Clara Caltrain station where I could take the VTA flier (bus route 10), took about 50 min to an hour (again because of transfers)...
Because Silicon Valley is so spread out, the bus transfers and the frequency are total killers in trying to get from point-A to point-B (unless those points are walking distance to light-rail or caltrain). Even on medium frequency routes, there is little bus service because it centers on community college routes and retail locations like the El Camino Real corridor (which they are looking to upgrade) and the 87-to-cisco corridor. Unfortunately, it's a pain in the ass for any other potential user because sub-urban sprawl makes the population density sucks for bus service.
Yeah I voted for the VTA tax increase, but I have the suspicion they are probably just gonna spend it on prep-work for the California high-speed rail project, not making any better transit system in the valley...
This is difficult to answer, since TAOCP is tied in with my early education. I went through all three volumes more than once, although I never solved all the problems. (The third exercise is to prove Fermat's Last Theorem. In my copy, it's listed as difficulty HM50 (HM for Higher Mathematics, 50 was a major large-scale research project on his more or less logarithmic scale), and I've heard it has been demoted to HM47 in later editions.).
A lot of TAOCP is excruciatingly detailed analysis of stuff approximately nobody actually cares about anymore. Some of it is completely inapplicable nowadays, such as exact timings of programs. The half-volume on sorting is primarily concerned with in-memory and tape sorts, for example, and the intricacies of different sorting methods with multiple tapes are of no use today. In the original three volumes, everything was single-threaded, although coroutines were in Volume 1. There are good algorithms books nowadays, and I don't remember any but TAOCP back then.
Most of TAOCP is of little practical use nowadays. Pretty much everything it covers is taken care of in libraries in modern computers (or even in hardware, such as floating-point numbers). There's much that's useful for someone who wants to understand how the libraries do what they do, or even create one. I used Volume 2 as the foundation for my entry into a programming contest to do 32/64-bit multiplication and division efficiently on a Z80 (about the only time I used the dual register banks)..
What I gained from it was partly fundamental education and deep understanding and partly mindset. I can't honestly say what anyone would get out of it, although I'd suggest anyone who's interested in what's underlying what they do read part of it and give it a good shot.
"When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
See subject: If anyone is the lunatic here, it's clearly you. My ware is not a malware & I have tons of valid verifiable reputable sources proving it here https://ask.slashdot.org/comments.pl?sid=9954349&cid=53422667 and apparently you're all out of "downmod points" to try "hide" that, lmao... you lose!
* BUT, that's what you always do, don't you? Yes... lol!
APK
P.S.=> Stalking me around & trolling me by unidentifiable anonymous posts with your libelous failed attacks on me only proves my points all the more - thank you for being SO stupid in that... apk
Other than to impress people who only looked impressed and secretly think your nuts to have them on your bookshelf.
If you have a question Google it! Odds are someone somewhere has faced a similar issue and has come up with a solution you can borrow, use, steal..
Knuth is giving his annual Christmas lecture on Thursday, Dec 8, 2016, at 6:00 pm PST in the Huang Engineering Center's NVIDIA Auditorium. It will be webcast. See: http://www-cs-faculty.stanford... All of the previous lectures are online.
Volume one was my textbook for Algorithms many, many years ago, so I read it. I read volumes two and three when they first came out. I read some of the bits of volume four A. When I read 1-3, they were the best or only sources of their content. One of the key features is the use of assembly language for a mythical computer (later revised to be more RISC-like). i wrote an interpreter for MIX for my computer architecture class. Possible programming languages in the 1960s were FORTRAN, COBOL, ALGOL-60, IBM's PL/I, and IBM-s APL, and compilers did not optimize. The obvious real computer architecture to use was the original IBM 360 instructions set (Principles of Operation). Choosing any one of those would obsolete the books in five to ten years after publication.
My fantasy is to publish the draft of the original two volume Art of Computer Programming, started in 1962. When he started rewriting it, he planned for seven volumes, which are outlined on the end papers of the published volumes. The two volume original is a snapshot of Computer Science in the early 1960's.
when it's all finished, and available in digital format.
PHP has many many idiosyncrasies that violate the principle of least astonishment.
Programming is made to be complex. Unlike surgery and aerospace engineering, you make up your own rules with programming. It's like you can make a virtual world with all kinds of useful laws of physics. Of course, the more complex you make these laws, the more difficult it becomes. Most programmers, given enough time, will turn any project into a ball of mud.
https://www.cs.virginia.edu/~evans/cs655/readings/ewd498.html
Dijkstra on Cobol and Basic. Bias worse than yours towards PASCAL, even if it happens to be true.
I only look human.
My mother is a halfling and my dad is an ogre, so that makes me an Ogreling
Don't feel bad. These things build (unsigned) char-acter.
Tee-hee.
Of course, that's still assuming your architecture has eight bits per byte. -PCP
No, none of that assumes anything 8-bit, except by that fact that CHAR_BIT cannot possibly be *less* than 8.
And even then, the minimum allowable ranges of integer types are actually specified in terms of intervals, not in terms of bit widths.
I.e. it's perfectly valid to implement C on a 13-bit platform and still have unsigned char be able to hold values no bigger than 65535. Likewise, regardless of how many bits per byte, signed char need not be able to hold values outside [-127, 127] (no, not -128)
(My brainfart does not mean I don't know my C.)
CLI paste? paste.pr0.tips!
You are correct. Thanks for clarifying that.
It takes a lot of thought processes to write simple (and good) code. It's kind of like writing in general (text). It's easy to write out thoughts, but for most it takes a lot of work to make it clear and compact.
I can re-visit any page of manuscript and code I've written and usually find ways to simplify and improve it: remove redundancies (factor), use better variable names or pronoun references, etc.
And I'm sure if more readers visits it, they will have suggestions for further improvement: more perspectives help. I know how my head processes info, but we are usually writing for other heads.
There is probably a point of diminishing returns, but the first few drafts of code or manuscript are rarely close to being optimized.
Table-ized A.I.
See subject & https://ask.slashdot.org/comments.pl?sid=9954349&cid=53422587/ downmodded unjustifiably 1st! Here's more:
I support APK's stand on the hosts file by Trax3001BBS
Your premise that hostfiles are a good way to deal with advertising and malvertising is quite valid by JazzLad
No complaints from me, I like APK... Reminds me to use a host file. Also, his stuff is free by aaaaaaargh!
APK's monolithic hosts file is looking pretty good by Culture20
APK... Awesome to see he's still spreading the good word by Molochi
ABP is insufficient as a solid hosts file does everything that APK reminds us about by fast turtle
APK isn't wrong by cfalcon
APK, I know people give you a lot of shit regarding hosts, but please don't ever stop by nasredin
You need APK's hosts file by Teun
APK solution STILL relevant by Thud457
you're right about hosts files by drinkypoo
APK
P.S.=> Want more? EAT YOUR WORDS while stalking me by unidentifiable posts loser... apk
The pascal article was satire, in defense of abstractions by "Ed Post" (whose name I thought was a stand-in for 'editorial post' when I saw it,) in 1982. A lot of the crochetty old nerd guard was getting antsy about making computing into the use of a 'black box' or simply bragging about their arcane skills, and bemoaning that the programmers of today wouldn't be able to hand toggle their way out of a locked filing cabinet. Same as some linux folk (who are becoming increasingly rare,) who insist that anything you can't do on a command line isn't worth doing. Like all satire, there is some merit. But mostly it's just good laughs of the "Get off my lawn" variety. Thanks for that link.
Speak for yourself.
See subject: 1st take your meds mentalcase https://slashdot.org/comments....
&
I see you're also a druggie too https://slashdot.org/comments....
Going to make more sockpuppets to stalk & troll me with you loon https://slashdot.org/comments.... ?
+
Your sending me postcards with threats too https://slashdot.org/comments.... ?
* You're a butthurt loon freak, plain & simple... you did it to yourself, loser.
APK
P.S.=> Still trying to live down how I shot you to pieces in the art & science of computing Mr. Butthurt https://slashdot.org/comments.... ?
How about proving hosts & my program that builds them are useless too https://slashdot.org/comments.... ?
See subject above - They're FACT & your fails made them so, lol!
(I've done all that LONG ago & you haven't done squat of note... must hurt like hell, that truth, or you wouldn't be stalking me like the loser druggie mental loon you're proven to be in YOUR OWN WORDS in those links above, lol)... apk
I'm calling BS on Silicon Valley having a well-developed transit system.
I live in San Jose and work in Palo Alto. Most mornings it takes me exactly one hour from my front door to take a local bus down the street, pick up the express bus to Palo Alto, and another local bus to the front door of my workplace. The afternoon commute is one to two hours long, depending on 280 traffic. Or four hours if a gravel truck spills across all lanes like it did a few months ago.
http://www.nbcbayarea.com/news/local/Gravel-Truck-Overturns-Blocks-Multiuple-Lanes-on-I-280-394043641.html
VTA transit routes (e.g., the transit agency responsible for mess that is silicon valley) have decided that the only viable transit corridors/routes are south san jose to downtown san jose and mountain view to cisco (aka north-sanjose).
That's correct. Homes in the South and jobs in the North determined the transit lines back in the 1980's. VTA was supposed to have a half-dozen East-West light rail lines but those were never built. When San Carlos got shutdown as a street through San Jose State University in the 1990's, the county built the foundations and covered it up with 18 inches of top soil for a future light rail line. The only major East-West line being built is the BART extension from Fremont.
Santa Clara (in the heart of Silicon valley)
Santa Clara (Intel) haven't been the heart of Silicon Valley in decades. It's Menlo Park (Facebook).
[...] (unless those points are walking distance to light-rail or caltrain).
That's why mixed-developments with stores on bottom and four story of apartments on top are sprouting up along the transit lines. If you don't live near a major transit line and don't work near a major transit line, blaming public transit isn't going to fix it. I live near several major transit lines, so I'm an hour away from work in North San Jose, Mountain View or Palo Alto.
I made it through V1 and half of volume 2 a few years ago, and found myself frustrated.
For myself, Godel Escher and Bach feels to me to be more useful as a programmer mindset book (or is that just me) or Unix Power Tools for practical guidelines,
And yeah - a lot of it is above my level of mathematical sophistication - I topped off at modern algebra, and I concede I fin it frustrating that I can have a reasonable grasp of number theory, encryption, and matrix arithmetic, and still be going "Wait, whut?" in these.
An Invisible Entity of Vast Power whose existence must be taken on faith alone: Liberal Media
It was the best comprehensive collection of information at the time it was published, and it's all still valid (if somewhat dated as far as specific examples). What has changed is the tradeoffs and power of systems. If you're not doing tiny/cheap embedded applications, you don't care about economizing quite as much. OTOH the concepts of algorithmic complexity are even more important than before because of the huge scale of online systems.
We actually used the first two volumes in my computer science classes some years ago. Computer languages and GUI frameworks come and go - mathematics is forever. I actually needed to use Euclid's algorithm (circa 300BC) in a program and Ada Lovelace's method for computing a Bernoulli number on a mechanical computer no less is just as valid as the day she wrote it.
I've occasionally thought about reading it, but one of the things that always stopped me is doubts about how relevant it still is today. Could you comment on that?
This book was written when computers only had one core and multithreaded algorithms weren't a thing. When there wasn't such a thing as vector units, to say nothing of massively parallel processors like GPUs. When performance was entirely determined by computation, whereas today it's often dominated by memory access. The factors that go into designing a good algorithm today are really different from what they were in the 1970s.
Even aside from that, there's been a lot of progress since then. Maybe it's a great reference for 50 year old sorting algorithms, but there are better algorithms known today.
"I'm too busy to research this and form an educated opinion, but I do have time to tell everyone my uninformed opinion."
I own all of them, but to be honest I haven't cracked any book at work since at least 2009. I work on a web services-based POS, a fairly advanced but typical piece of technology for the working world. My comment shouldn't apply to programming in a research environment, but most people aren't doing that type of programming. I'm talking about your average piece of software.
Most programming "in the real world" is maintaining other people's code and making incremental improvements.
The first art of computer programming is figuring out other people's mistakes and correcting them. The second art of computer programming is communicating the work you've done to the next person. The third art is writing code that is so straightforward that an inexperienced programmer can understand what you did so that he can fix your bugs and make his own incremental improvements.
The information in textbooks and books such as TAOCP has been available online for a decade. On the rare occasion that you as a programmer have to do a computer science-y thing, a Google search followed by research is your best course of action. Using books is just outmoded nowadays.
I've been programming since the 1980's so take this with a grain of salt. If you still use your dead tree library then more power to you. There is a different style of programming for every programmer. We have three full-time programmers here and we all have radically different styles but we barely write down anything and there isn't a single programming book in our current office. We barely use paper anymore. I personally write down no more than about 50 words a week.
There is a philosophy I subscribe to that if you can't explain something to your mother, then you don't understand what you're doing well enough. TAOCP is dense stuff. The information is there, and it is conveyed correctly. But that's the science, not the art, of computer programming. Sorry, Knuth.
Back in high school, I thought I was the most badass programmer on this planet. Could hand assemble code and hyper-optimize my programs counting clock cycles everywhere. I got into college. There was a book on algorithms in the small library the computer room had. I learned about asymptotic behavior. So I realized that my cleverly optimized O(n^2) sorting assembly program was going to eventually lose badly to a straightforward interpreted implementation of quicksort. Clearly I had to become good at this. I started reading all books I could find on the topic and very quickly I noticed that they all included a sentence meaning "If you want to understand the subtle underpinnings of this, see TAOCP." So I got a copy of volumes 1 & 3. It was expensive (I was not in USA and books were VERY expensive because of currency exchange issues). Mom & Dad chipped in and I still thank them for that. I borrowed volume 2 from a friend.
I decided to go though the book solving all exercises up to level 30. Saturday was my TAOCP day. I cannot say I read ALL of the text nor that I solved ALL problems of difficulty below 30, but I solved all that I tried and they were way more than a few. I even solve some in the 35 level, whenever I considered them interesting.
FF to the beginning my PhD studies at a good school in the USA: When taking the grad level Algorithms class, I was doing VERY well. The professor, a scary smart guy (now full professor at Stanford) asked me how may courses on algorithms and information theory I had taken. The answer was none. My undergrad degree was in Systems Engineering, from a crappy school in South America. I was never formally taught what a big-Oh was. That professor become my thesis advisor. He used to joke saying I was a walking encyclopedia of algorithms.
Will it work for everybody? Probably not. If you want to do theoretical CS, as I did, you will have to handle that math and some more anyways. CLR is more up to date and time efficient for learning. If you want to be a software engineer, chances are you are not going to be doing the heavy math, you will be using off the shelf algorithms.
Still TAOCP is a hell of a reference. Funny thing is, after finishing my PhD, I browsed through it. It looked simple, not very formal at all. I guess PhD does mean "permanently head damaged" :-)
... you can try Godel, Escher, Bach: An Eternal Golden Braid for some light reading
It is often said that a software architect is your best programmer. The architecture is highly dependent on the implementation and the implementation is highly dependent on the architecture. If the architect is not good at implementation, you get an ivory tower issue.
It is actually part of the architect's responsibility that they make sure the system is implemented the way they envisioned. Leaving the implementation details up to the developer or programmer is just asking for trouble. The responsibility of the architect does not stop at the software. They are also responsible for the hardware and network.
The architect is supposed to take a holistic approach and understand EVERYTHING from security to hardware to optimizations. Ideally, you have exactly one architect and everything is made to fit their vision. In practice, people leave companies, take vacations, and other thing happen. You might have one or two co-architects. It doesn't matter the size of the project, one person to rule them all. If you have more than one person, you will not get seamless integration among the many systems. The end goal is you have one unified vision, and you can't have that with more than one leader.
'supposed to be" ???
clearly you haven't been paying attention. All the attack vectors we currently have in code are because of the lack of coders, er, uh, sorry, I know you prefer the term 'developers' these days, don't do any-damn-thing about doing inputs testing or overflow, invalid input, etc.
So, don't climb on your high horse and lecture about how the 'best textbook' doesn't teach a damn thing about them, when that led to the code we now have to try to make secure.
So, also, if all that is, "... a given...", then why is none of it done reliably????
Ramble ramble, gurrr gurrr, hear me roar.
Oh, I've been paying attention. A significant chunk of my professional experience (22 years) has been involved in secure programming and in scanning and fixing vulnerabilities left by accident (or more often than not, by incompetent developers) in the commercial and defense sectors. I'm not exaggerating that my entire career has been devoted to fixing other people's fuck ups. So when I say something it is (most likely) because I have some experience in the matter. I am not an authority in the matter, nor I claim to know it all, but I sure make sure to check my premises when I speak.
People are sloppy, plain and simple. Cobbling security concerns in an algorithm book accomplishes nothing. There are tomes and tomes of material out there regarding secure development, security and what not. There are online encyclopedias devoted to secure programming in, say, Java or C/C++. A entire web site (https://www.cert.org/secure-coding/) is devoted to canonical attack vectors and remediations. There are industry standards out there, for anyone to read, regarding secure coding. Take the MISRA C guidelines or the Ada Ravenscar Profile for examples.
If people aren't bothered to even do a fucking google on the most common attack vectors when developing a web site or a device driver, what makes you think they will pay attention when technology-specific secure coding details are embedded in text designed for mathematical description of algorithms?
It is called separation of concerns. That exists for a reason, and any secure developer worth a damned shit knows why. Separation of concerns does not mean ignorance of concerns. The fact that you do not know the importance of this (and its implications) made me suspect the quality of the work you (if you do any work at all.)
You do not pick a book about Operating Systems or Hardware Architecture and expect a description of routing protocols, do you? If you pick a book on security, say, attack vectors or public key infrastructure, you do not expect to find a discussion on lower or upper bounds for a distributed hash algorithm, do you?
Same deal with security. You pick a book about security, and you study it. You pick a book about algorithms and you study it. You pick a book about operating systems, and you study it. You pick a book about networking, and you study it. And so on, and so on. And you do so throughout your studies and continue to do so throughout your career.
Expecting all shit to be cobbled together in the same book gets you one of those mediocre "Be a Rock Star Programdude in 24 Hours" kind of a deal.
Sorry to bust your bubble, but it is people like you that litter the software industry with crap that the rest of us have to clean. I guess I should be thankful for it, because fixing shit written by others (specially when it is critical) can be a financially rewarding experience.
Have you ever written code targeting platforms like the HP Saturn family of microprocessors? Such machines use nibble-based addressing, where the smallest individually addressable unit is 4 bits wide, so you might quite sensibly elect to "#define CHAR_BIT 4" for certain toolchains operating in such environments. Provided you don't have any insurmountable technical requirements stipulating C89 or later so far as "standards adherence" goes, this would be fine in terms of "K&R C." CHAR_MIN and CHAR_MAX are entirely separate concerns, though. -PCP
These should be in every programmers library... they will never become dated... so I would not be afraid to call them classic.
These are fantastic books, but they are not meant to be read cover to cover. They are reference volumes. Before the Internet this was what we had.
:-)
Had to laugh at the posters that say the books are too hard. In the early days of software development you wrote your own database...from scratch. Your program started with a loop that read the keyboard... You decided what key did what... You wrote your own screen handler... In the early days of the PC you modified the memory of the video card directly to draw things... So if you wanted a circle, you needed to know geometry!
I'm not saying those days were better by any means but algorithms do to things like maintain tree structures for your database indexes was a VERY hot topic of discussion around the "Dat water cooler.... And yes, I'm old
Murphy was an optimist
Well I was talking about Standard C (de-jure, K&R C was de-facto at best), but interesting real-world reason to violate it regardless. No, I haven't had the pleasure with 4 bit MCUs yet.
CLI paste? paste.pr0.tips!
99.99% of the time it's just a mountain to climb. Mountain climbing is good exercise though.
There are designers, who are creative, and programmers, who are code monkeys.
There are binary thinkers, who are tools, and people with cognitive nuance, who are awesome.
I picked it up again some 5 years ago, and the pseudo-assembly code totally turned me off
Logic is Universal. It does not mean you will come to the same conclusions because of many factors including knowledge, experience, and personal preferences. The logic used to reach the conclusion should be easy to understand for other logical people.
A tip off that you're not thinking logically is if you need to constantly change your mental model. There has been research where a logic test is given to students entering a Computer Science major. They used a pseudo-code language with no rules given and told the students to interpret it. Several examples of input and output for the language were supplied, then a question was asked about a different input, what was the expected output. They gave this test several times throughout the student's carriers. consistency was key. Students who came to the same conclusion, even if they were "wrong", were typically the best programmers. They even tried this test out on students with zero programming background and in other majors, and they got similar results.
Regardless of knowledge or experiencing gained, if you can't come to the same conclusion for a logic test, it's because you're not being logical.