Most Popular

1500 questions
83
votes
7 answers

Why are bit masks called "masks" and what purpose do they serve?

Why are "bit masks" called like this? I know that they are mainly used for bitwise operations and the usage of bit masks is more efficient than the usage of separate variables. However my question is why and when were bit masks invented? Were they…
yoyo_fun
  • 2,297
83
votes
12 answers

What's actually wrong with an endpoint returning HTML rather than JSON data?

When I first started learning PHP (about 5 or 6 years ago) I learned about Ajax, and I went through "the phases": Your server returns HTML data and you put it inside a DOM's innerHTML You learn about data transfer formats such as XML (and say "oooh…
83
votes
2 answers

Why are concurrent writes not allowed on an SQLite database?

I am doing database programming using Java with SQLite. I have found that only one connection at a time to the database has write capabilities, while many connections at once have read capability. Why was the architecture of SQLite designed like…
SteelToe
  • 1,559
83
votes
4 answers

Should we include the NuGet PACKAGE folder in version control?

In a C# or VB.NET project, should we include the PACKAGE folder (NuGet package folder that is created in the root of my project that contains the nupkg files and other content) to our source control repository (Git for instance)?
83
votes
1 answer

Is there a difference between fibers, coroutines and green threads and if that is so what is it?

Today I was reading several articles on the Internet about fibers, coroutines and green threads, and it seems like these concepts have very much in common, but there are slight differences, especially when we talk about fibers and coroutines. Is…
DejanLekic
  • 963
  • 1
  • 7
  • 8
83
votes
8 answers

Why do so many projects prefer "git rebase" over "git merge"?

One of the advantages of using a DVCS is the edit-commit-merge workflow (over edit-merge-commit often enforced by a CVCS). Allowing each unique change to be recorded in the repository independent of merges ensures the DAG accurately reflects the…
83
votes
2 answers

Why is there a "new" in Go?

I'm still puzzled as why we have new in Go. When you want to instantiate a struct, you do t := Thing{} and you can get a pointer to a new instance by doing t := &Thing{} But there's also this possibility : t := new(Thing) This last one seems a…
83
votes
22 answers

How do developers find the time to stay on top of latest technologies?

I was a freelance web developer until circa 2004 when I started going down the management route but have decided to try to get back into development again (specifically JavaScript and HTML5 web/mobile web apps) and I really get the impression to be…
83
votes
11 answers

Why is Scheme my first language in university?

I hear about C, C++, Java every day whenever people starting talking about computer science, but in my first computer science class we are asked to write in Scheme (DrRacket). Why is that? What differences will this make to my future understanding…
Erica Xu
  • 1,131
  • 1
  • 8
  • 12
83
votes
14 answers

What should take precedence: YAGNI or Good Design?

At which point should YAGNI take precedence against good coding practices and vice versa? I'm working on a project at work and want to slowly introduce good code standards to my co-workers (currently there are none and everything is just kind of…
Wayne Molina
  • 15,684
82
votes
6 answers

How should I determine my rates for writing custom software?

For a custom software that will likely take a year or more to develop, how would I go about determining what to charge as a consultant? I'm having a hard time coming up with a number, and searches online are providing vastly different numbers…
Carson Myers
  • 2,480
82
votes
6 answers

When to go Fluent in C#?

In many respects I really like the idea of Fluent interfaces, but with all of the modern features of C# (initializers, lambdas, named parameters) I find myself thinking, "is it worth it?", and "Is this the right pattern to use?". Could anyone give…
Andrew Hanlon
  • 923
  • 1
  • 7
  • 7
82
votes
18 answers

What is the best way to discern an excellent programmer in a job interview?

In the setting of an interview: What is the best way to reliably identify when somebody is an excellent programmer. By this I mean he is one of those that is 10-15 times more efficient / rapid / better than his peers towards the lower end of the…
Claudiu
  • 779
82
votes
17 answers

How can software be protected from piracy?

Why does it seem so easy to pirate today? It just seems a little hard to believe that with all of our technological advances and the billions of dollars spent on engineering the most unbelievable and mind-blowing software, we still have no other…
Snowman
  • 445
82
votes
14 answers

When is optimization not premature and therefore not evil?

"Premature optimization is root of all evil" is something almost all of us have heard/read. What I am curious what kind of optimization not premature, i.e. at every stage of software development (high level design, detailed design, high level…
Gaurav
  • 3,729
  • 2
  • 26
  • 43