Reputation
6,013
Next privilege 10,000 Rep.
Access moderator tools
Badges
13 49
Impact
~212k people reached

1d
comment Do binary trees serve a specific purpose in storing hierarchical data? What is their canonical use?
This answer leaves out half of the reason why you want to use them: adding and removing elements. It's not only about access to elements: a sorted array would be just as fast as a binary tree.
Jun
26
comment What is faster? Using REST API or querying a database directly?
@JacquesB and the web app runs on the clients computer. So it shouldn't be trusted because it could be a modified version.
Jun
22
comment Simple and clean way of comparing three numbers
I don't understand your comment about DONT_KNOW , what if c is the smallest and a and b are the same? The algorithm would return that b is the biggest, while a is the same as b.
Jun
20
comment Retrieving maximum value from a range in unsorted array
what's the complexity of filling the tree?
Jun
17
comment What is faster? Using REST API or querying a database directly?
The "on the other hand" requires you to expose your database to the big bad world.
Jun
11
comment '<' versus '!=' as condition in a 'for' loop?
@KonradRudolph and < is exactly what you use to establish an upper bound. < for upperbound without edges, <= for upper bound with edges, != for telling 1 element is not in the set.
Jun
10
comment What is the best way to go about storing application options: file system or db?
Yup, make a generic interface for your options so you can use either a database or a file-system.
Jun
2
comment What stops C from being compiled/interpreted/JIT'ed?
I can emulate the x86-platform on most other platforms, as a virtual machine. Run my c-programs targeted there. How is that conceptually different from a "transparent"-virtual machine as the JVM ?
May
21
comment Is it okay to go against all-caps naming for enums to make their String representation simpler?
+1 for : Let an enum be an enum and a string be a string.
May
21
comment Is it okay to go against all-caps naming for enums to make their String representation simpler?
Maybe not use the "sting form" of an enum? An enum is an enum and I think it's a bad design choice to have a stringrepresentation of it.
May
19
comment How do I communicate to a colleague that their code does nothing?
What will this code do in the case that int n is int_max ? Take just a long time? Throw an exception? That's definitely side-effects in my book.
May
8
comment How to quickly search through a very large list of strings / records on a database
In my opinion the fulltext options in any RDBMS is a workaround to make it do something it isn't designed for: "search in some pile of unstructured unrelated data". If you're building a searchengine, you just don't use an RDBMS. It may work for small datasets but lakcs any sort of scaling. Searching through piles of unstructured data is not a nail, so don't use a hammer. Use the right tool for the job.
May
8
comment How to quickly search through a very large list of strings / records on a database
The problem as stated doesn't seem like a good fit for an RDMS anyhow.
May
6
comment Read complex data from a relational database through a join or through concurrent requests?
Concurrent access to the database also has a lot of overhead.
May
6
comment What's the best way to handle Windows API errors in response to system messages or when I have nowhere to return them to?
@Deduplicator the harmless error are actually errors where you know what to do with them.
May
1
comment Finding the first index in which the element and the index are the same
Make code that keeps using the original list instead of recursive code that splits the list into new lists.
Apr
28
comment List comparing techniques for faster performance
50k and 400k aren't particularly big lists. two foreach cycles or Linq this will get you O(n^2) time complexity and yes that is a slow approach.
Apr
24
comment Is String processing more complex than number processing in programming languages?
In most programming languages strings are a layer of abstraction on top of numbers. So when you're processing strings, under the hood the computer translates it to numbers and processes numbers.
Apr
23
comment Using JOIN keyword or not
@RemcoGerlich why it has been deprecated isn't under discussion here. What's under discussion here is whether to use the old or new syntax. Whether one is better then the other or not is moot: you shouldn't use old syntax. The why question is another discussion. (one that has been settled 20 years ago.)
Apr
23
comment Using JOIN keyword or not
I also tend toward that style to minimize surprise I think you just answered your own question. Surprises are bad.