Obviously you didn't learn shit. NO MAGIC NUMBERS means:
I think the gp post is implying that the students didn't understand why "no magic numbers" was a problem, so they worked in magic numbers anyway without grokking why you would give a number a meaningful name.
Pizza is a pretty simple recipe, but how it is made largely defines how good it is. So I wrote up my technique here http://www.wavicle.org/~joe/pizza.html
What part of the country are you living in? It makes a huge difference.
I'm living in the Sacramento, just 80 miles outside of the bay. I have a lot of friends in the Bay Area, and for obvious reasons not a single one of them only makes $40K/yr. If you're going to hold up the worst possible cost of living next to a below-average starting salary for areas with a much lower cost of living, well it's gonna be a flawed argument. Secretaries make more money than that out there. I was offered more than that for a summer internship here.
When you were a single person, how much fun was it to cook for yourself, and be stuck with the same leftovers for a week? Believe me, I cook a lot for myself, but there's only so much hamburger/tuna/chicken helper I can take.
Which leads one to ask the obvious question... Why are you living alone? Why not get together with a friend and find a two bedroom place? That's what I did when I was single.
I know how to save money (and how to cook healthy), but god DAMN does it get old after the 4th day.
So is the cooking the real problem, or is the real problem that you've defined your social life around eating out?
Oh come on, that is ridiculous. My wife and I both think our family of four is living above our means going through $2,000 per month - even though most of that is spent on housing and utilities. We're managing to live comfortably on $24,000 per year.
What is costing a single person more than $2,200 per month?
I suspect it's the new car with bad gas mileage and new car insurance, the apartment in the trendy area where young singles are 'supposed' to hang out, eating out 12 times a week, $5 cups of starbucks 7 times a week and eating store-bought prepared meals when eating in.
(I regularly make a delicious pizza at home with just $4 of ingredients, patience and TLC)
1) Honda's ASIMO made a stop at my University a short time ago, I attended the VIP Technology Presentation when we got to grill the engineers on the technology behind ASIMO. You ought to shut it because you do not know what you are talking about. ASIMO is as much about the gyros, motors and hard plastic shell that people see as the computer software which interprets all the orientation data and keeps him upright.
2) I am currently the student voice lobbying for change in my school's CS program because the engineers are trying to start up a robotics & mechatronics lab, but are having trouble because while they can design all the hardware, they need something to make it work. Having every product depend on an operator's skill with a 9 channel radio controller just isn't cutting it. The robots that are currently working are either working because they require the full attention of a human operator or because of the high quality software running them.
Nothing motivates people to do unpleasant things like money will (see: the porn industry and Fear Factor).
Porn?!
Yeah, I never understood how some guy could tolerate having sexual intercourse with several women throughout the day or even at once. That's gotta be one of the most mind-numbingly-boring heart-breaking jobs around!:) How much would they have to pay him??
I once had a job at a place whose business was software to control provisioning and billing of broadband services. I was brought in to salvage a project that had gone terribly awry. For reasons which were NOT MY FAULT, one table of the database was designed with immutable rows. Once a record was written, it could only be deleted or read, never altered.
The problem was that at times they could never quite pin down, they would attempt to add a new entry to the database and things would fail unusually requiring the client software to be restarted and the whole transaction to be re-entered, at which time it would usually succeed.
The problem turned out to be two fold: First the real problem was being hidden by exception handling code that silently masked the fact that something had gone wrong. Once I fixed this I found the real culprit: since the rows were immutable but required a primary key, the guy designing the database came up with an ingenious solution: make a hash of the values the primary key! (This sounds like a lot of work, but because of the O-R mapping layer in place, it was actually less code) Since one of those fields was a current timestamp, the insert succeeded when they tried to do the insert after a restart.
He informed me, quite matter-of-factly, that I did not understand that hashes were unique, and therefore this was a quite reasonable thing to do. I tried and tried to explain to him that it simply was not possible to uniquely hash all combinations of n bits of information in a hash of size n-k (k > 1). But his expensive ITT (or was it Heald?) education seemed to trump any rational argument I posed.
The dumbass christian fundementalists majority is just too powerful a voting block.
Actually the dumbass christian fundamentalists are a small minority. It's just that they are smart enough to actually get out and vote and vote the same way.
If the dumbass freedom-loving liberals would get off their collective asses and make it to the ballot box, most polls show the majority of people who could vote favor liberal social policies.
I can't wait to see the fundies and the hookers, united against a common foe, descending on the Texas State Legislature to lobby against Porn at truckstops.
One of them can argue morality. The other can argue unfair government competition.
I wonder which of those arguments each of them will choose.
The Slippery Slope is a fallacy in which a person asserts that some event must inevitably follow from another without any argument for the inevitability of the event in question.
Arguing that something shouldn't be done because of the possibility it may lead down an undesirable path is not a fallacy. It's especially faulty to call it a fallacy when the argument is backed by an example that most would agree with.
I'll say it once: You don't live in a democracy. I'll say it again: You don't live in a democracy.
The majority rules when it comes to representatives, and it rules when it comes to local law (in some cases) as long as, and *only* as long as it doesn't violate the constitution.
You do realize you just described a constitutional democracy, right?
You could have a dozen kids, and still lose 0.024% of your genes forever. If you have two kids, a full 1/4 of your genes would never be transmitted to posterity.
You could have two kids and not lose a single one of your genes, however statistically remote that possibility is. It's also possible that your grandchildren could end up not carrying a single one of your genes, however very remote that possibility is. Sexual reproduction assures the greatest probability of as many of your genes as possible continuing on in perpetuity. It's the best deal your genes could hope for short of asexual reproduction which works great until a microbe comes along which overwhelms you - and every one of your identical progeny.
usually got lucky by knowing some trick to solve some particular problem.... and they also get used to the type of problems asked.
Those two comments are somewhat contradictory, but the second one is very true. I've done the ACM contest and the TopCoder contests, and nothing makes you so skilled at these types of problems as just doing a large number of them. My understanding is that the schools that place in the top ranks of their ACM region often have classes, or at least student clubs, focused on solving the problems.
For entirely practical reasons, the contests tend to focus on rather academic problems. They don't translate well into the real world (despite their real-world sounding description) but test your ability to detect whether a problem fits into a few broad categories of doability: brute force, depth first search, breadth first search, dynamic programming with memoization, etc..
Still, they are fun problems to do, and there is a fringe benefit: I can code solutions to academic assignments much faster than the other students I'm in class with. 4 hours of homework per week for them is about 15-20 minutes for me.
On a personal note though, I have to say that TopCoder is by far the better contest for one simple reason: learning. Those Ivory Tower elitists from the ACM have this idea that for some odd reason solutions and original data sets should not be published. Also, they are so focused on prevention of cheating that I didn't manage to get the code I wrote for the contest off of the machines. Having a USB flashdrive on your person would have been grounds for disqualification.
When I started doing TopCoder, I started getting much better at coding because after every match there was a posted commentary on how to do the solutions, *and* you could see *everybody's* solution, *and* you could see their original data set.
Because using recursion to calculate Fibonacci in the obvious way is a hideously inefficient algorithm.
The algorithm efficiency was NOT being tested. Recursion performance was being tested. How is using recursion for fibonacci not a valid test of recursion?
It's not a fair test of the ability to implement a real world algorithm efficiently in different programming languages, which is the only useful metric you're going to get out of that sort of test set-up.
No, that is incorrect. What is being tested here is how efficiently the language handles recursion.
Compare this with a divide-and-conquer algorithm like quicksort, or an algorithm over a recursive data structure like an insertion on a binary tree, where the use of recursion to implement the algorithm is natural and need not introduce these arbitrary overheads.
Both of those algorithms are highly sensitive to memory access latency, cache size, caching strategy, etc.. The memory access could easily become the dominant use of time. The question being asked with the fibonacci problem is "how well does the language handle recursion." This is not the best way to calculate a fibonacci number, but it is a very good way to test recursion-dependent issues such as stack frame usage without muddying the results with a large amount of calculations or random memory access.
Ok, the test description says that its task is to show the performance of recursion. But then they have to find a task where recursion is an merit - not a flaw.
Can you establish that more fully? How is testing say, a recursive-descent parser, going to be a more valid test of recursion than a recursive solution for fibonacci numbers?
Fibonacci is convenient because you get lots of recursive calls while only hitting the stack, and no integer overflow. If you were to use a recursive parser and python ended up slower than the others, you could easily blame it on the non-recursive work you were doing. The fibonacci example allows you to accurately describe the recursive performance without all that other stuff getting in the way.
You are committing a lot of equivocation. Primarily you are linking "computers" with "the environment I run on my computer."
Computers are quite complex. Why can't software be produced that has the same rate of failure as the typical bridge, skyscraper or HVAC unit? Because the complexity of software running on a computer is substantially higher. You do realize the reason you know of so many engineering failures is because they stand out against a pattern of very high success, right? The number one reason an update to software is released: new problems found with the previous version.
Obviously you didn't learn shit. NO MAGIC NUMBERS means:
I think the gp post is implying that the students didn't understand why "no magic numbers" was a problem, so they worked in magic numbers anyway without grokking why you would give a number a meaningful name.
That is they didn't understand:
MAX_VALUE = 17;
if ( x > MAX_VALUE )
vs.
SEVENTEEN = 17;
if ( x > SEVENTEEN )
You should have written a function to generate the list of numbers for you:
Pizza is a pretty simple recipe, but how it is made largely defines how good it is. So I wrote up my technique here http://www.wavicle.org/~joe/pizza.html
Hope it helps!
In Silicon Valley, 2200 won't pay your rent.
Actually it will, with room to spare, but thank you for playing.
What part of the country are you living in? It makes a huge difference.
I'm living in the Sacramento, just 80 miles outside of the bay. I have a lot of friends in the Bay Area, and for obvious reasons not a single one of them only makes $40K/yr. If you're going to hold up the worst possible cost of living next to a below-average starting salary for areas with a much lower cost of living, well it's gonna be a flawed argument. Secretaries make more money than that out there. I was offered more than that for a summer internship here.
When you were a single person, how much fun was it to cook for yourself, and be stuck with the same leftovers for a week? Believe me, I cook a lot for myself, but there's only so much hamburger/tuna/chicken helper I can take.
Which leads one to ask the obvious question... Why are you living alone? Why not get together with a friend and find a two bedroom place? That's what I did when I was single.
I know how to save money (and how to cook healthy), but god DAMN does it get old after the 4th day.
So is the cooking the real problem, or is the real problem that you've defined your social life around eating out?
Oh come on, that is ridiculous. My wife and I both think our family of four is living above our means going through $2,000 per month - even though most of that is spent on housing and utilities. We're managing to live comfortably on $24,000 per year.
What is costing a single person more than $2,200 per month?
I suspect it's the new car with bad gas mileage and new car insurance, the apartment in the trendy area where young singles are 'supposed' to hang out, eating out 12 times a week, $5 cups of starbucks 7 times a week and eating store-bought prepared meals when eating in.
(I regularly make a delicious pizza at home with just $4 of ingredients, patience and TLC)
The difference between a computer engineer and a computer science major is that the engineer knows the meaning be hind the numbers/bits in product.
What product exactly is being referred to?
I really thinks programmers need to know more hardware to better write their software.
Which software are you talking about? "Software" encompasses an awful lot.
Okay, two things:
1) Honda's ASIMO made a stop at my University a short time ago, I attended the VIP Technology Presentation when we got to grill the engineers on the technology behind ASIMO. You ought to shut it because you do not know what you are talking about. ASIMO is as much about the gyros, motors and hard plastic shell that people see as the computer software which interprets all the orientation data and keeps him upright.
2) I am currently the student voice lobbying for change in my school's CS program because the engineers are trying to start up a robotics & mechatronics lab, but are having trouble because while they can design all the hardware, they need something to make it work. Having every product depend on an operator's skill with a 9 channel radio controller just isn't cutting it. The robots that are currently working are either working because they require the full attention of a human operator or because of the high quality software running them.
We all pity the intellectual failing of those unable to discern tongue-in-cheek humor. Maybe there's a support group.
Nothing motivates people to do unpleasant things like money will (see: the porn industry and Fear Factor).
:) How much would they have to pay him??
Porn?!
Yeah, I never understood how some guy could tolerate having sexual intercourse with several women throughout the day or even at once. That's gotta be one of the most mind-numbingly-boring heart-breaking jobs around!
The majority rules when it comes to representatives
That describes a democratic election process.
and it rules when it comes to local law (in some cases)
In those "some cases", it is a direct democracy.
as long as, and *only* as long as it doesn't violate the constitution.
And that makes it a constitutional democracy.
The whole of the process described "majority rule unless it violates a constitution" is a constitutional democracy.
I once had a job at a place whose business was software to control provisioning and billing of broadband services. I was brought in to salvage a project that had gone terribly awry. For reasons which were NOT MY FAULT, one table of the database was designed with immutable rows. Once a record was written, it could only be deleted or read, never altered.
The problem was that at times they could never quite pin down, they would attempt to add a new entry to the database and things would fail unusually requiring the client software to be restarted and the whole transaction to be re-entered, at which time it would usually succeed.
The problem turned out to be two fold: First the real problem was being hidden by exception handling code that silently masked the fact that something had gone wrong. Once I fixed this I found the real culprit: since the rows were immutable but required a primary key, the guy designing the database came up with an ingenious solution: make a hash of the values the primary key! (This sounds like a lot of work, but because of the O-R mapping layer in place, it was actually less code) Since one of those fields was a current timestamp, the insert succeeded when they tried to do the insert after a restart.
He informed me, quite matter-of-factly, that I did not understand that hashes were unique, and therefore this was a quite reasonable thing to do. I tried and tried to explain to him that it simply was not possible to uniquely hash all combinations of n bits of information in a hash of size n-k (k > 1). But his expensive ITT (or was it Heald?) education seemed to trump any rational argument I posed.
It would be a democracy if we voted directly on everything, rather than electing representatives to do so for us.
I see. So if a democracy is limited by a written constitution, it is called a democratic republic?
(hint: did you actually read what was written?)
The dumbass christian fundementalists majority is just too powerful a voting block.
Actually the dumbass christian fundamentalists are a small minority. It's just that they are smart enough to actually get out and vote and vote the same way.
If the dumbass freedom-loving liberals would get off their collective asses and make it to the ballot box, most polls show the majority of people who could vote favor liberal social policies.
I can't wait to see the fundies and the hookers, united against a common foe, descending on the Texas State Legislature to lobby against Porn at truckstops.
One of them can argue morality. The other can argue unfair government competition.
I wonder which of those arguments each of them will choose.
Yeah, let's take the first link:
The Slippery Slope is a fallacy in which a person asserts that some event must inevitably follow from another without any argument for the inevitability of the event in question.
Arguing that something shouldn't be done because of the possibility it may lead down an undesirable path is not a fallacy. It's especially faulty to call it a fallacy when the argument is backed by an example that most would agree with.
I'll say it once: You don't live in a democracy. I'll say it again: You don't live in a democracy.
The majority rules when it comes to representatives, and it rules when it comes to local law (in some cases) as long as, and *only* as long as it doesn't violate the constitution.
You do realize you just described a constitutional democracy, right?
You could have a dozen kids, and still lose 0.024% of your genes forever. If you have two kids, a full 1/4 of your genes would never be transmitted to posterity.
You could have two kids and not lose a single one of your genes, however statistically remote that possibility is. It's also possible that your grandchildren could end up not carrying a single one of your genes, however very remote that possibility is. Sexual reproduction assures the greatest probability of as many of your genes as possible continuing on in perpetuity. It's the best deal your genes could hope for short of asexual reproduction which works great until a microbe comes along which overwhelms you - and every one of your identical progeny.
usually got lucky by knowing some trick to solve some particular problem. ...
and they also get used to the type of problems asked.
Those two comments are somewhat contradictory, but the second one is very true. I've done the ACM contest and the TopCoder contests, and nothing makes you so skilled at these types of problems as just doing a large number of them. My understanding is that the schools that place in the top ranks of their ACM region often have classes, or at least student clubs, focused on solving the problems.
For entirely practical reasons, the contests tend to focus on rather academic problems. They don't translate well into the real world (despite their real-world sounding description) but test your ability to detect whether a problem fits into a few broad categories of doability: brute force, depth first search, breadth first search, dynamic programming with memoization, etc..
Still, they are fun problems to do, and there is a fringe benefit: I can code solutions to academic assignments much faster than the other students I'm in class with. 4 hours of homework per week for them is about 15-20 minutes for me.
On a personal note though, I have to say that TopCoder is by far the better contest for one simple reason: learning. Those Ivory Tower elitists from the ACM have this idea that for some odd reason solutions and original data sets should not be published. Also, they are so focused on prevention of cheating that I didn't manage to get the code I wrote for the contest off of the machines. Having a USB flashdrive on your person would have been grounds for disqualification.
When I started doing TopCoder, I started getting much better at coding because after every match there was a posted commentary on how to do the solutions, *and* you could see *everybody's* solution, *and* you could see their original data set.
Hmmm, let's put this to a simple numbers test...
People unknowingly buying illegally cut wood: Millions
People cutting wood illegally: Thousands
Easier to stop, according to you: Millions.
People consuming drugs: Millions
People producing drugs: Thousands
Easier to stop, according to you: Millions.
Hmmm...
Because using recursion to calculate Fibonacci in the obvious way is a hideously inefficient algorithm.
The algorithm efficiency was NOT being tested. Recursion performance was being tested. How is using recursion for fibonacci not a valid test of recursion?
It's not a fair test of the ability to implement a real world algorithm efficiently in different programming languages, which is the only useful metric you're going to get out of that sort of test set-up.
No, that is incorrect. What is being tested here is how efficiently the language handles recursion.
Compare this with a divide-and-conquer algorithm like quicksort, or an algorithm over a recursive data structure like an insertion on a binary tree, where the use of recursion to implement the algorithm is natural and need not introduce these arbitrary overheads.
Both of those algorithms are highly sensitive to memory access latency, cache size, caching strategy, etc.. The memory access could easily become the dominant use of time. The question being asked with the fibonacci problem is "how well does the language handle recursion." This is not the best way to calculate a fibonacci number, but it is a very good way to test recursion-dependent issues such as stack frame usage without muddying the results with a large amount of calculations or random memory access.
Ok, the test description says that its task is to show the performance of recursion. But then they have to find a task where recursion is an merit - not a flaw.
Can you establish that more fully? How is testing say, a recursive-descent parser, going to be a more valid test of recursion than a recursive solution for fibonacci numbers?
Fibonacci is convenient because you get lots of recursive calls while only hitting the stack, and no integer overflow. If you were to use a recursive parser and python ended up slower than the others, you could easily blame it on the non-recursive work you were doing. The fibonacci example allows you to accurately describe the recursive performance without all that other stuff getting in the way.
Now what are they going to call the next version?
OS Aleph Null
You are committing a lot of equivocation. Primarily you are linking "computers" with "the environment I run on my computer."
Computers are quite complex. Why can't software be produced that has the same rate of failure as the typical bridge, skyscraper or HVAC unit? Because the complexity of software running on a computer is substantially higher. You do realize the reason you know of so many engineering failures is because they stand out against a pattern of very high success, right? The number one reason an update to software is released: new problems found with the previous version.
I am happy they got rid of GNOME, I think they should merge KDE, FVWM and CDE into the one true desktop.
KFCOffice
(apologies to thosed blessed enough to live where there is no KFC and thus don't 'get it')