Most Popular

1500 questions
171
votes
12 answers

How do operating systems… run… without having an OS to run in?

I'm really curious right now. I'm a Python programmer, and this question just boggled me: You write an OS. How do you run it? It has to be run somehow, and that way is within another OS? How can an application run without being in an OS? How do you…
Thor Correia
  • 1,433
170
votes
5 answers

Scheme vs Common Lisp: Which characteristics made a difference in your project?

There are no shortage of vague "Scheme vs Common Lisp" questions on both StackOverflow and on this site, so I want to make this one more focused. The question is for people who have coded in both languages: While coding in Scheme, what specific…
170
votes
1 answer

Understanding the differences: traditional interpreter, JIT compiler, JIT interpreter and AOT compiler

I'm trying to understand the differences between a traditional interpreter, a JIT compiler, a JIT interpreter and an AOT compiler. An interpreter is just a machine (virtual or physical) that executes instructions in some computer language. In that…
Aviv Cohn
  • 21,388
170
votes
10 answers

Mono is frequently used to say "Yes, .NET is cross-platform". How valid is that claim?

In What would you choose for your project between .NET and Java at this point in time? I say that I would consider the "Will you always deploy to Windows?" the single most important technical decision to make up front in a new web project, and if…
user1249
169
votes
9 answers

I changed one method signature and now have over 25,000 errors. What now?

I started a new job recently where I am working on a very large application (15M loc). In my previous job we had a similarly large application but (for better or for worse) we used OSGi, which meant the application was broken down into lots of…
user788497
  • 1,321
169
votes
18 answers

Is there any reason to use C++ instead of C, Perl, Python, etc.?

As a Linux (server side) developer, I don't know where and why should I use C++. When I'm going for performance, the first and last choice is C. When "performance" isn't the main issue, programming languages like Perl and Python would be good…
Ehsan
  • 853
169
votes
17 answers

Why are part-time jobs in programming an anomaly?

I've recently quit my full time developing job at mega-corp, and I decided that I'll look for a part time job. Since then I've talked to half a dozen potential employers, and every one of them had the same reaction when I said the magic words…
Mikle
  • 302
169
votes
18 answers

Is it better to return NULL or empty values from functions/methods where the return value is not present?

I am looking for a recommendation here. I am struggling with whether it is better to return NULL or an empty value from a method when the return value is not present or cannot be determined. Take the following two methods as an examples: string…
P B
  • 2,369
  • 3
  • 16
  • 10
167
votes
1 answer

Where can I find programming puzzles and challenges?

I'm trying to find places where I can hone my craft outside the context of school or work. Are there places online, or books available, where I can access lists of programming puzzles or challenges?
cmcculloh
  • 1,025
167
votes
28 answers

How to be a zero-bug programmer?

My boss has always told me that a good programmer should be able to ensure that the code he or she changes is reliable, correct, and thoroughly self-verified; that you should completely understand all the results and impacts your changes will cause.…
Elaine
  • 261
167
votes
8 answers

Criticism and disadvantages of dependency injection

Dependency injection (DI) is a well known and fashionable pattern. Most of engineers know its advantages, like: Making isolation in unit testing possible/easy Explicitly defining dependencies of a class Facilitating good design (single…
167
votes
10 answers

Is there a specific reason for the poor readability of regular expression syntax design?

Programmers all seem to agree that readability of code is far more important than short-syntaxed one-liners which work, but require a senior developer to interpret with any degree of accuracy - but that seems to be exactly the way regular…
J.Todd
  • 3,823
166
votes
111 answers

Are there any famous one-man-army programmers?

Lately I have been learning of more and more programmers who think that if they were working alone, they would be faster and would deliver more quality. Usually that feeling is attached to a feeling that they do the best programming in their team…
DFectuoso
  • 111
165
votes
5 answers

How to detect the encoding of a file?

On my filesystem (Windows 7) I have some text files (These are SQL script files, if that matters). When opened with Notepad++, in the "Encoding" menu some of them are reported to have an encoding of "UCS-2 Little Endian" and some of "UTF-8 without…
Marcel
  • 3,112
  • 3
  • 19
  • 19
165
votes
6 answers

Should the variable be named Id or ID?

This is a bit pedantic, but I've seen some people use Id as in: private int userId; public int getUserId(); and others use: private int userID; public int getUserID(); Is one of these a better name than the other? Why? I've seen this done very…
Adam
  • 2,181