Reputation
2,895
Top tag
Next privilege 3,000 Rep.
Cast close & reopen votes
Badges
13 30
Newest
 Yearling
Impact
~137k people reached

Jun
18
comment What were the Design Patterns of the procedural programming era?
OOP having its roots in C++??? Kids these days... :(
Jun
18
comment Can I consider interface methods as abstract methods?
Is this Java code?
Jun
18
comment Resources for functional programming beginner
@PaulNathan Disagreed. LYAHFGG is an awesome resource for beginners to functional programming. It certainly helped me, and I knew nothing about Haskell's type system. It's not enough for advanced users, but that's not its purpose. Real World Haskell might be better for that.
Jun
18
revised How to teach Exception Handling for New Programmers?
code formatting
Jun
17
comment Reason for return statement in recursive function call
OP: is your code snippet written in C?
Jun
17
comment Reason for return statement in recursive function call
Downvoters: please realize that, depending on the background of the OP, it's not at all obvious what return does. In fact, in functional languages (and some mixed ones, like Scala) return is not needed: the value of the recursive function is the value of its last expression. Simply writing search_list(l->next, x) without return would have worked in Scala! The meaning of the return statement is only obvious to programmers with an imperative background.
Jun
17
comment Forcing people to read and understand code instead of using comments, function summaries and debuggers?
@Mikey Needless to say, I don't like this. I'd rather we all wrote good, clean code. I just think the notion that what matters the most is building good, clean, well-commented software is incredibly naive in the real world. And that writing bad code won't necessarily put you out of business, unlike what we'd like to believe.
Jun
17
comment Forcing people to read and understand code instead of using comments, function summaries and debuggers?
@Mikey I wouldn't say it's always entirely management's fault, though that plays a big part too. I've seen too many mediocre programmers who just don't care, so I cannot blame everything on management. I also doubt mediocrity is a surefire way to go out of business, unless you're building mission critical software and you lack any friendly contacts in the customer's side. It's amazing how far you can go with crap, hard to maintain software. And it's top business for outside contractors who eventually get paid to rebuild it from scratch.
Jun
16
comment Forcing people to read and understand code instead of using comments, function summaries and debuggers?
@Mikey Oh, fully agreed. My remark was merely a sort of "meanwhile, in the real world..." What you say is definitely valuable. Unfortunately, in the real world people seldom write comments or, for that matter, good code.
Jun
16
comment Forcing people to read and understand code instead of using comments, function summaries and debuggers?
But isn't the real world with deadlines the one in which many people are forced to write crappy code without comments or any sane identifier naming whatsoever? :P "I'll write comments and refactor this piece of c...ode later. Not enough time now, must deliver this for yesterday!"
Jun
14
comment When is it a good time to reason about performance in Haskell?
This answer is too broad and not very helpful for Haskell. Assume the OP already knows about macro vs micro optimization. How does this answer apply to Haskell, a non-strict language for which it is harder to reason about runtime and memory performance?
Jun
14
comment Programming as fast as you can touch-type… How to get to that stage?
I agree with your answer, but with the caveat that "being a good, fast programmer" is about solving problems fast, not typing fast. Typing is simply not the bottleneck for anything but the most trivial problems.
Jun
14
comment Programming as fast as you can touch-type… How to get to that stage?
Unless you are a particularly clumsy typist, typing speed is not an issue. Programming isn't about typing fast.
Jun
13
comment Is Haskell function composition an instance of pipe & filter architectural pattern
What is a CPO category? My google-fu is weak :(
Jun
13
comment Which design patterns would I use for this algorithm?
Why do you think you need a pattern here?
Jun
13
comment What did Rich Hickey mean when he said, “All that specificity [of interfaces/classes/types] kills your reuse!”
@GlenPeterson Yes, you are right. Or rather, instead of "dynamic" (which do assign "named" types to the value) I'd say "languages with structural typing", such as Clojure. Note that what you suggest, rather than a full-blown solution is actually a trade-off; what you gain in flexibility you lose in type safety (which is what static typing addresses!). BTW, I'm no expert and might have got the details wrong ;)
Jun
12
comment What features should a programming language have to say it has good reusability?
OOP is by no means a requirement for code reuse.
Jun
12
comment Why is Python written in C and not in C++?
@ott Indeed, that question does make sense: why isn't the standard implementation of Python written in Python? It follows that the designer of Python likes his own language, so the question is interesting.
Jun
12
comment Why is Python written in C and not in C++?
@PiotrDobrogost That's a strawman. It's obvious why you wouldn't want to write modern, non-performance critical code in assembly. Your question is different though: "why C instead of C++?". Let me reverse the question: "why C++ instead of C?". Or worse: "why C++ and not Pascal. I like Pascal more!"
Jun
12
comment Why is Python written in C and not in C++?
I fail to see the point of asking "why is (popular program) written in (language X) and not (language Y)?". Or rather, the same question can be reversed: why Y and not X?