Reputation
54,715
Next tag badge:
225/100 score
19/20 answers
Badges
10 155 239
Newest
 Good Answer
Impact
~1.7m people reached

Jul
23
comment i'm getting this error in python<__main__.Node object at 0x03A5F990> linked list
Where in the code does the error take place? Do you have a stack trace?
Jul
23
revised i'm getting this error in python<__main__.Node object at 0x03A5F990> linked list
added 102 characters in body
Jul
21
comment Clean Abstract Syntax Tree
@NSAddict: The way you "keep the bases clean" in a multi-pass compiler and make things easy to reason about is with a well-defined pipeline. Each step uses the Visitor Pattern to perform a certain operation on the AST. You can then reason that, at any given stage of the pipeline, the AST will be in a certain well-defined state because all of the transformations performed by all previous stages will be complete by that point. Keeping complexity of mutable data down to a comprehensible level is really not that difficult; you just need to apply some discipline and definition.
Jul
21
comment Clean Abstract Syntax Tree
@NSAddict: Sorry. It's just that I've never understood the "difficult to reason about" line, and people who use it always state it as a fact, (or at least an article of faith,) with no evidence provided or (apparently) required, even though the burden of proof should be on the person making the claim. It's hard for someone who reasons about stuff like this all the time to see a claim like that and not come to the conclusion that the problem actually lies with the person who seems to find this to be some really hard thing to do.
Jul
21
answered Clean Abstract Syntax Tree
Jul
13
comment Is the question “What is the using statement” a bad question to ask an interviewee?
@JeffO: To Google something, first you have to know what you're looking for. That's not always an obvious thing.
Jul
13
answered Is the question “What is the using statement” a bad question to ask an interviewee?
Jul
13
comment What are some good books to use to learn ADA?
ADA is the Americans with Disabilities Act. The programming language is written "Ada".
Jul
12
comment The Critical Functionality of an API has changed, what should I do?
Google: "Don't be evil." Facebook: "Don't even bother pretending we're trying not to be evil."
Jul
10
answered How to suspend open source support?
Jul
9
reviewed Approve Can static and dynamically typed languages be seen as different tools for different types of jobs?
Jul
1
awarded  Enlightened
Jul
1
awarded  Nice Answer
Jun
29
comment Do binary trees serve a specific purpose in storing hierarchical data? What is their canonical use?
@sw123456 Glad I could help explain it :)
Jun
29
comment Do binary trees serve a specific purpose in storing hierarchical data? What is their canonical use?
@sw123456: That's right. As with any engineering, it comes with tradeoffs, (uses more--and more fragmented--memory than an array with the same number of elements, O(n) access to element #n of the data set rather than O(1) access, etc,) but fast search is definitely the major benefit of binary trees.
Jun
29
answered Do binary trees serve a specific purpose in storing hierarchical data? What is their canonical use?
Jun
29
comment Is method overriding always a violation of Liskov Substitution Principle?
Overriding isn't intrinsically a violation of LSP; it's the entire point of LSP.
Jun
27
awarded  object-oriented
Jun
26
comment Can you implement “object-oriented” programming without the class keyword?
The Linux kernel uses an emulation of several OO techniques, which all have to be coded manually without language support. This leads to plenty of opportunities for bugs, which, being Linux, is counterbalanced by a liberal application of Linus's Law. Yes, it's possible to do--Turing equivalence proves this--but my point that it's extremely difficult to get right without language support still stands. Also, why all these questions about C when the question was about Python? In C it's not possible to do the nested functions trick in the first place.
Jun
26
comment Can you implement “object-oriented” programming without the class keyword?
@overexchange: Those are structs with function pointers, not objects with methods. They're assigned at runtime, can be reassigned, can be null or corrupt if you screw up somewhere, add a dereference overhead each time they're invoked, and add sizeof(pointer) per "method" to your struct instance size. Real methods have none of the above disadvantages. (Except the dereference overhead, which applies to virtual methods.)