Live data from Hacker News

The limited value of a computer science education

nathanmarz.com

161–163 of 163 posts

Re: The limited value of a computer science education

#161

Earlier quoted context omitted.

I also don't see why one would necessarily need to reason from complexity arguments, rather than more intuitive "I'm using a set because I want to use set operations like union and membership". If performance is crucial, reasoning by complexity analysis is not sufficient and often not even necessary.

This becomes tricky when you're using a language like Ruby where arrays also have built-in union and membership operations. And I don't see why, if performance is critical, knowing which operations/techniques/algorithms are orders of magnitude slower than others wouldn't be useful (it has been for me).

With higher level languages it's even less important to know theoretic complexities, just represent the problem in the most natural representation and optimize later. (You're already giving up orders of magnitude in exchange for dev time by using a higher level language.) Good engineering practices like being able to swap out structures and algorithms later matter a lot more.

Operations/techniques/algorithms are great to know when performance is critical, the subset knowledge of worst-case time and space complexities not really. (And in interviews do you ask for best case or average-under-certain-probability-distributions cases? How expansive is the trivia matrix you get candidates to fill in?) They can sometimes help guide, but they'll just as often mislead. Bubble sort and insertion sort are both n^2 algorithms, but you should never use bubble sort, and if you never profile you'll be confused why my quicker quicksort uses insertion sort inside when n is small since quicksort is n * log(n) so it should always be better right? (Conveniently ignoring worst case for quicksort is n^2 because people usually just memorize the n * log(n) factoid.) Or you'll be confused why I don't use quicksort at all if I have multiple CPU cores to create a parallel algorithm on. Throw in other aspects of modern hardware like caches (try swapping the loop order in code that needs to loop over all cells in an NxM matrix and note how much performance can suffer if you do it wrong) and branch prediction and special instructions your CPU architecture supports, those are very good to know too if you care a lot about performance. For complexity analysis in the real world, "constants matter", but that doesn't really capture all of the caveats.

Maybe the classic case of my overall point is the existence of https://en.wikipedia.org/wiki/Simplex_algorithm#Efficiency

Edit: one interview problem I like to give (given I have to give one and can't do things my preferred way) is the jump game: https://leetcode.com/problems/jump-game/ Rot13 commentary: Bar fbyhgvba vf whfg qrcgu-svefg frnepu. Va Clguba zl pbqr sbe gung vf 12 yvarf, vg hfrf n fgnpx (jvgu n abezny clguba neenl; vg pna or n dhrhr gbb vs lbh whfg punatr gur nethzrag gb .cbc()) naq n frg, ohg lbh pbhyq whfg hfr n cynva neenl sbe rirelguvat. V yvxr guvf ceboyrz fvapr vg yrgf zr frr vs gur crefba xabjf ubj gb nccyl bgure fgehpgherf orfvqrf cynva neenlf. N ybg bs crbcyr pna erpnyy gur rkvfgrapr bs frgf naq dhrhrf naq znlor svyy va gurve pbzcyrkvgvrf bs PEHQ bcrengvbaf ba n zngevk ohg pna'g npghnyyl nccyl gurz be nal nytbevguzf orlbaq ovanel frnepu naq gur onfvp PEHQ vzcyrzragngvbaf sbe rnpu onfvp fgehpgher.

Re: The limited value of a computer science education

#162

Earlier quoted context omitted.

Huh. I'm a 2nd year undergrad atm, and came across an instance of the nurse scheduling problem at my on-campus job. I did some research and delved into evolutionary computation, eventually deciding on genetic algorithms to solve my schedule problem. (I'm using a self-adapted version of NSGA II) Anyways, all my research has gotten me very interested in all the topics you mentioned, also neuroevolution. I actually brou…

I can only point you to the book we used at the time: Computational Intelligence: An Introduction http://jasss.soc.surrey.ac.uk/7/1/reviews/ramanath.html Although there were many class handouts and journal papers we had to read too.

Thanks - at this point I have looked through as much material on the subject since my project really only involves genetic evolution and multi objective optimization. Time to dive in!

Re: The limited value of a computer science education

#163

Earlier quoted context omitted.

While it's clear many university institutes and projects have benefited the wider public, I think he was specifically referring to the value of university to an individual, for most people (excepting those who are studying sciences to enter a specific niche field where they wouldn't be able to pick up the necessary skills anywhere else) university is indeed a waste of time and money. I'm a 22 year old developer based…

> I'm a 22 year old developer based in Australia, I've been working in the web industry full time since I was 18 and been earning money all along. You're conflating Comp Sci with programming. I think it's pretty clear you don't need CS to be a productive developer, especially if the kind of work you're interested in doing involves building small to medium size websites and CRUD apps using other people's libraries and…

Well yeah, I'm certainly only doing high-level stuff, if I wanted to do low level systems programming, OS/language design or anything with hardware at a lower level than whatever APIs existing drivers provide then a CS degree would certainly come in handy.

I was more getting at the fact that for probably the majority of people who go to university, they're pretty much wasting their time and money because unless they're looking to do something that can't be self-taught or learned on-the-job, they could be gaining the same skills (and maybe even getting paid for it) without putting themselves in debt that they'll spend a decade or more paying off.

For example, all the lessons capote claims to have learned doing CS at uni, I learned on the job while getting paid for it.

I have no doubt that a uni education would benefit anyone, I'm just saying that I think for the vast majority of people going to uni, the costs they're ultimately paying don't outweigh the benefits they gain, unless they're going to uni to enter a high paying field which requires a degree to enter the industry at all such as law or medicine. Unless the career you want absolutely requires a degree, you probably don't need one.

Post reply on HN