11,078 reputation
34064
bio website
location Waco, TX
age 29
visits member for 4 years, 6 months
seen 28 mins ago
My native language is C++, but I have left my first love and now use python whenever I have the slightest excuse. Actually, I use python even if I don't have an excuse.

17h
awarded  Good Answer
1d
awarded  Nice Answer
1d
answered Dynamic Code Evaluation in Java - Clever or Sloppy?
1d
comment Dynamic Code Evaluation in Java - Clever or Sloppy?
What is the benefit of trying to push these business rules into a database over putting the logic into the compiled application?
Mar
23
comment How are basic functions implemented in a programming language if they are not built in?
But in general, either its implemented in the language using the same constructs you use as a programmer of the language, or its built-in.
Mar
23
comment How are basic functions implemented in a programming language if they are not built in?
@Melab, asking for the general method is what makes it broad. There is no general method, every language does things a bit differently.
Mar
22
answered How hidden classes allows faster access to properties in google's V8?
Mar
14
comment How do you iterate through an array and delete an element?
For more details see: stackoverflow.com/questions/322715/…, or a do google search for "don't use linked lists". The fact is, there are cases for LinkedList, but they are rare. You certainly shouldn't be suggested that novices default to them.
Mar
14
comment How do you iterate through an array and delete an element?
On the practical level, ArrayList are much faster to iterate because all you have to do is increment a counter, which is very fast. Linked Lists have to dereference a pointer and jump to a completely different place in memory. Both of those are slow operations. ArrayLists do have to move data for some operations, but moving blocks of data while O(n) is a fast operation. Its actually much faster then the LinkedList iteration process.
Mar
14
comment How do you iterate through an array and delete an element?
I'm afraid your discussion of LinkedList is inaccurate. Firstly, on a theoretical level you can't make that distinction between O(length) and O(index). Yes, your index is probably on average length/2, but O(length/2) = O(length). The fact is, all the operations you discuss have the same big-O for both LinkedList and ArrayList. The LinkedList only has a better big-O if you somehow already have the iterator for an individual element you want to operate on. That's true for some algorithms, but its rare.
Mar
6
comment Are there any languages that don't need to be compiled? when dealing with c#
@JörgWMittag, you are being ridiculously pedantic. Please stop trying to make yourself out to be smarter then everyone else on the internet and focus on conveying useful information.
Mar
5
comment Are there any languages that don't need to be compiled? when dealing with c#
@JörgWMittag, that's not what I said. I nowhere made any claim that any language was interpreted or compiled. My claim was specifically that C# is commonly executed via JIT interpretation. You seemed to be claiming in your comment that there was "zero JIT compiled implementations."
Mar
5
awarded  Good Question
Mar
5
comment Are there any languages that don't need to be compiled? when dealing with c#
@JörgWMittag, unless I'm mistaken the C# compilers you point out compile to bytecode which is interpreted/JIT compiled at runtime.
Mar
1
answered dynamic programming with memoization
Feb
27
comment The recommended Way to exit a Loop
In my opinion, this is a particularly goofy solution that I've only seen endorsed in academic contexts. The point of avoiding GOTO is to increase the clarity of code, and the opposite is accomplished by adding boolean flag variables to control flow.
Feb
25
comment Why are there no java compiler alternatives to allow new functionality?
Technically, you could devise a compiler of Java++ to JVM bytecode. You can compile just about anything to JVM bytecode if you really wanted to. However, since Java's rules about methods and classes are actually implemented at the bytecode level you'd have to work around those rules, and forgo compatibility with previously compiled code.
Feb
10
comment How do I enforce 'referential transparency' in this program?
why do you want to? Are you doing it as an excersize, or is there some practical goal you have mind?
Feb
9
comment What is the rule for nested loop code?
What makes you think that "nested loops" like this aren't used frequently in software engineering? Have you tried creating an example to see what happens?
Jan
19
comment should I test this public method
@Maximus, I'm afraid I think that's a very bad idea. Introducing a mock in this testing will make the tests more complex, include more implementation details, be harder to follow, be less helpful as documentation, and provide a shallower test of your functionality. The only possible advantage to introducing a mock here is to prevent tests on validator from failing because of bugs in storage. But I think that's an almost worthless benefit.