Reputation
2,118
Top tag
Next privilege 2,500 Rep.
Create tag synonyms
Badges
7 19
Newest
 Enlightened
Impact
~32k people reached

Jun
19
comment Benefits of classic OOP over Go-like language
+1 for "not necessarily the best one". Citing Alan Kay: "I invented the term Object-Oriented, and I can tell you I did not have C++ in mind." (nor did he have C# and/or Java, I would humbly guess)
Feb
14
comment New to TDD. Should I avoid private methods now?
"It's my understanding that private methods make objects more encapsulated, thus more resistant to change and errors. Thus, they should be used by default and only those methods that matter to clients should be made public." This seems to me like counter point of view of what TDD is trying to achieve. TDD is development methodology that leads you to create simple, workable and open-to-changes design. Looking "from private" and "only publicize..." is turned around completely. Forget there is such a thing as a private method to embrace TDD. Later, do them as needed; as a part of refactoring.
Jan
11
comment What are the complexities of memory-unmanaged programming?
Missed free is not the worst thing. Early free is much more devastating.
Jan
10
comment Automatically update copyright date range from git?
You should add a year / enlarge range whenever you do substantial change to a file, afaict. So the raason is there. Problem is, it should not be automatic - git cannot tell when the change is substantial.
Dec
22
comment What would be an appropriate algorithm to factorise numbers in the range of a few billion?
I'd say using isPrime is an overkill. Just doing n/=2 while n%2==0 and then starting i with 3 and then looping if (n%i==0) n/=i; else i+=2; is enough (well, it can be stopped once i*i > n).
Dec
17
comment What language/framework/workflow sets do you recomend for a small office?
And if you are going to do thing like Ericsson does (telephone switches that must work with lot of concurrent data and heal from failures) go for Erlang.
Dec
13
comment How should semi-agile team operate during management-imposed waterfall-like “testing phase”
Ok, not from scratch, but by treating old code as legacy and poisoned and instead of "fixing bugs" simply refactor and nothing more, using all methods that are used to work with legacy code, making it right in the process. The bosses can hear about "big fixing" if they need to, though it will be really just "development done right at last".
Dec
9
comment Why is it impossible to produce truly random numbers?
Are you really asking why you cannot produce truly random number on a deterministic device? Doesn't the question already include the answer?
Dec
8
comment Is Dijkstra's algorithm an appropriate solution to this signal routing problem?
@PeterTaylor: Would it matter if they were multiplicative? They have exact same semantics as additive (provided they are positive) by applying a logarithm. Or is it something more complicated behind it?
Dec
6
comment Is Dijkstra's algorithm an appropriate solution to this signal routing problem?
@KimBurgess: Edited the answer.
Dec
6
comment Is Dijkstra's algorithm an appropriate solution to this signal routing problem?
@PeterTaylor: Interesting. Any source, please?
Dec
6
comment Is Dijkstra's algorithm an appropriate solution to this signal routing problem?
@PéterTörök: In that case, yes. Only the asker knows for sure. But when it is a tree, bfs is enough (and dead simple).
Dec
3
comment How did you pick up the art of solving real life problems? Can you shortcut the process?
@Maxood: Please, Smalltalk is not written with capital T. Thanx.
Dec
3
comment How did you pick up the art of solving real life problems? Can you shortcut the process?
@Maxood: Not at all. If you don't know the broad range of what (OO) programming is, your C++ (or whatever else) knowledge is just the desperate try. To use C++ (or whatever else) to its full extent, you must first know the concepts well, and then plug C++ into them, seeing what it really is. From my own experience, nothing learns you OO better (especially in world dominated by Java and C++) then Smalltalk. You then see C++ in context. You can then really use it as it was meant (because you see it in comparision).
Dec
2
comment How do you define, organize, and document your data?
Form: What I wanted to stress out is that someone who uses term 'OO-oriented classes' looks like a 13-year-old kid who just read his first book about OO and now wants to evangelize the rest of the world (not that you are be one, but the term is suggesting that way). Content: I'd oppose that objects (and restriction-enforcing constructors) are the answer. It can be answer in a monolithic environment. But if you pass data around between client written in JS and server written in PHP or whatever, and it can pass it along to something else, you need data, not the constructors for each language.
Dec
2
comment How do you define, organize, and document your data?
What's an 'OO-oriented class'? What other types of classes are there?
Dec
2
comment Elegant ways to handle if(if else) else
I use for(;;) just because do { } while(0) is longer. :-)
Dec
1
comment Where is the M in MVC?
The "real" controller of the old true MVC does processing of user inputs. The "misunderstood" controller of today's frameworks, which is fact Presenter and the pattern is MVP, not MVC (I'm talking about you, asp.net-mvc), the Presenter does some UI-related logic and is the mediator between the model and the view, since they are not directly connected any more (as they are in true MVC via Observer pattern).
Dec
1
comment Where is the M in MVC?
In the extreme case, when business logic is in the DB itself, you can have very thin model that mostly relays to the DB, or even say that db is your model (but then, it should have all the logic).
Dec
1
comment Where is the M in MVC?
Definitely. Nicely phrased.