What's your most controversial programming opinion?
stackoverflow.com
stackoverflow.com
I've seen lots of failed projects with smart, super-conscientious developers, who wouldn't write a method without a test. And others with programmers that frequently copied code, used globals for side effects, basically did everything they tell you not to do, but they produced programs that people loved using.
The difference was rapid iteration with real customers. This flushed out important bugs, even with code that was written in a way that was prone to be buggy. But more importantly, the developers quickly understood the product in a more global sense -- what was relevant to users and what wasn't. I suspect rapid iteration can turn even mediocre developers into stars.
It's important to recognize that good practices are about tradeoffs. The truly good developer is not the one that never copies code; it's the one that knows when it is the more fruitful course of action. So in a way, you need to be brilliant to get away with being sloppy.
i think some developers put too much stock in unit testing and it gives them (and their managers, customers, and co-workers) a false sense of security. they end up wasting time and not really preventing as many bugs as they think it will. application logic changes and they have to write twice as much code to change the application and all of the tests that depended on that logic.
writing a regression test for a complicated routine or library is one thing, but writing a test for every method of a class just for the warm fuzzy of their test framework telling them they have 100% coverage is silly.
I've seen so many programmers start writing so much better code after adding the criterium "it has to be testable".
BTW, the killer bugs are usually not in the "complicated routine". They are more often in the simple things programmers like to think they can do so perfectly that they don't need to write tests for it. I have found many a bug in the most simple one line functions I never bothered to test.
Just wait until you need to actually write an automation test and dealt with code/developers who happen to say "well, it's hard to do that now since we have tightly written code".
Ship sinking from that point onward.
Here's mine: if you haven't gone through a respectable 4 year CS program, odds are I'm not going to want to hire you since your brain isn't wired to think about algorithms and data structures instead of code and servers.
http://www.stlport.org/resources/StepanovUSA.html
I find OOP technically unsound. ...
I find OOP philosophically unsound. ...
I find OOP methodologically wrong. ...
http://www.infoq.com/presentations/The-DCI-Architecture (at around 39:30) You cannot do object-oriented programming in Java.
What the first calls OOP, the second calls "class-oriented programming". What the second calls proper OOP, I think is more along the lines of what the first advocates.It's not often you see comment sections with that dynamic. One is prompted to respond with something that will essentially relegate them to the bottom of the page.
You may choose to support a two-point comment using an upvote, perhaps only to see it voted back down a minute later. Controversy in plain sight?
I assume that's increasingly controversial :)
Read http://www.perlmonks.org/index.pl?node_id=48495 for more detail and a back and forth argument on it.
Also: One line code comments in front of a block of code should actually be converted into function calls that execute the described functionality. (comment is made redundant)
It seems as if people argue for the language they picked up first / have most experience in.
I believe the correct answer is not a direct answer, but something along the lines of "it doesn't matter, so long as you learn several, well".
I learned C first, stopped studying C when I tried to make a GUI for win32. ~2 pages of code for an empty window. ~5 lines in Python.
So, the ideal first language is whatever is easy to understand and fast to accomplish something. Instant gratification, in other words.
Should one learn the fundamentals first (assembly/C) or the practical first (python)? The answer will depend from person to person. I personally took the practical first approach.
[1] http://www.johndcook.com/blog/2010/03/03/just-in-case-versus...
(But I can't see a path from here to there. Especially one that involves getting paid to write an OS worth using.)
http://en.wikipedia.org/wiki/Singularity_(operating_system)
http://research.microsoft.com/en-us/projects/singularity/
See also: http://en.wikipedia.org/wiki/Midori_(operating_system) .
There's been a lot of this stuff happening around. There are many paths - which unfortunately cannot include many of the existing native (unsafe) solutions.
Many companies aren't going to need educated software engineers anymore because more and more software apps and code are given out for free. They will still need developers to make custom changes, but at less pay and less education (think mechanic instead of engineer). It will make it that much easer to outsource your job to India.
I have already seen this happening.
This is so "controversial" that some nice fellow here on HN both called it "crazy" and up voted it because of that.
My current "one big file" is 16555 lines of code long (javascript/nodejs). GVim handles it perfectly.
What I mean is that as an industry, we're in the stone ages. What we're doing will be looked back upon the same way that look back at bloodletting that was practiced by doctors a few hundred years ago.
Just when I think I'm beginning to get a grip on things, a whole new layer opens up, and I start over as a beginner again. I've heard anecdotal evidence that programmers who have been around 30 or 40 years still experience this.
EDIT: Not to be all self-promotey, just more of a "I agree with you so much I wrote about it."
I was coming from kind of a dictator view where I accept patches rather than blindingly letting people commit changes to projects i'm responsible for.
It is completely unprofessional to implement a solution you've been asked for, if that solution is bad practice.
That is to say, if you're asked to make a hack that will cause pain and misery, has a security risk attached, won't be performant or other clear, obvious risks, it is unprofessional to not object and in some cases, refuse.
There's too much fragmentation among programming languages. For instance, I think Ruby, Python, Perl and PHP all solve the same set of problems. One must win for the greater good. The benefits of unifying the developer community outweigh the benefits of diversity. There I said it :)
Maybe that's not the same thing as "too many" opinions; like when people have opinions on something they have no experience with.
I've always preferred it when people have strong, but weakly held opinions. [1]
[1] http://bobsutton.typepad.com/my_weblog/2006/07/strong_opinio...
They're just the BASIC equivalent of jumps in assembler. GOSUBS are just calls. If they're really so bad, why are their assembler equivalents used in almost every program in every architecture?