27,910 reputation
246108
bio website coderscentral.blogspot.com
location Colorado Springs, CO
age 49
visits member for 3 years, 10 months
seen 2 days ago

Started programming on a Control Data mainframe in FORTRAN IV, back when that was still a new thing. Was apparently quite masochistic, because I kept programming anyway. For that matter, I still do...

Gold C++ badge #20
Gold C badge #12
Legendary badge #35


Jul
2
comment How bad is it calling println() often than concatenating strings together and calling it once?
I see you don't know what ad hominem means either. An ad hominem argument is one of the form: "this argument should not be believed because the person making the argument is evil.". I simply pointed to the fact that your argument made no sense: the subject of discussion is levels of abstraction, yet you proclaim that abstractions are irrelevant. That's a solid indication that you don't understand the subject.
Jul
2
comment How bad is it calling println() often than concatenating strings together and calling it once?
@Phoshi: Ignoring abstractions indicates that you don't understand the subject matter, since abstraction is exactly what's under discussion.
Jul
2
comment How bad is it calling println() often than concatenating strings together and calling it once?
@Phoshi: Try with resources isn't even vaguely similar to RAII. RAII allows the class to manage the resources, but try with resources requires the client code to manage the resources. The features (abstractions, more accurately) that one has and the other lacks are entirely relevant--in fact, they're exactly what makes one language higher level than another.
Jul
2
awarded  java
Jul
1
comment How bad is it calling println() often than concatenating strings together and calling it once?
@200_success: Java doing the string concatenation at compile time seems to come down to §15.18.1: "The String object is newly created (§12.5) unless the expression is a compile-time constant expression (§15.28)." This seems to allow but not require that the concatenation be done at compile time. I.e., the result must be newly created if the inputs are not compile-time constants, but no requirement is made in either direction if they are compile time constants. To require compile-time concatenation, you'd have to read its (implied) "if" as really meaning "if and only if".
Jul
1
comment How bad is it calling println() often than concatenating strings together and calling it once?
Actually, it's Java that requires explicit memory management. In C++ I write something like: MyClass c; and it allocates an instance of MyClass. In Java I have to use MyClass c = new MyClass(); to allcoate it. Better still, RAII let's me automate management of other resources as well, where Java forces me to use a try/catch/finally in a lame imitation of what C++ destructors provide much more cleanly. Your own argument leaves us with only one reasonable conclusion: Java is a lower level language handicapped by lower-level I/O facilities.
Jul
1
comment How bad is it calling println() often than concatenating strings together and calling it once?
Throughout I point to the objective basis for Java being the lower level language. Not sure what line terminators you're talking about.
Jul
1
answered How bad is it calling println() often than concatenating strings together and calling it once?
Jun
13
comment Memory read/write access efficiency
If it's small enough to allocate directly on the stack, that's almost always preferred.
Jun
13
comment Memory read/write access efficiency
Correct about memory usage. Efficiency can vary. On really small microcontrollers and such, memory access may be faster than multiplication, which could make 3 a poor choice. As for a fourth option: perhaps avoid using malloc at all and allocate the data directly on the stack (but note that this often imposes a much lower restriction on size).
May
10
comment How are the skills used in typical interview questions applied in the real job?
@MainMa: That doesn't surprise me--that's why I repeated "as he's phrased it" a couple of times in my answer.
May
10
answered How are the skills used in typical interview questions applied in the real job?
Apr
26
comment In Java, what are checked exceptions good for?
@owlstead: Thanks--I probably should have been more careful with the wording there. The point wasn't so much that you actually had to catch the exception as it was that every intermediate level of code needs to be aware of every exception that might flow through it. As for the rest: having a tool that makes it quick and easy to make a mess of your code doesn't change the fact that it's making a mess of the code.
Apr
26
revised In Java, what are checked exceptions good for?
added 10 characters in body
Apr
26
revised In Java, what are checked exceptions good for?
added 4 characters in body
Apr
19
awarded  Good Answer
Apr
5
awarded  Nice Answer
Mar
4
revised Difference between networking programming and socket programming
added 193 characters in body
Mar
4
awarded  Nice Answer
Mar
3
awarded  Good Answer