10
votes
6answers
833 views

Struggling with the Single Responsibility Principle

Consider this example: I have a website. It allows users to make posts (can be anything) and add tags that describe the post. In the code, I have two classes that represent the post and tags. Lets ...
0
votes
2answers
512 views

Who can change the View in MVC?

I'm working on a thick client graph displaying and manipulation application. I'm trying to apply the MVC pattern to our 3D visualization component. Here is what I have for the Model, View, and ...
2
votes
1answer
572 views

Querying key/value store

I don't know whether this question is reasonably answerable (and therefore will be closed), but I will take my chances: What are the possible problems (and solutions), one might encounter, when ...
2
votes
1answer
797 views

What's the point of initializing a variable with the same value twice? [closed]

I was reading Ben Cherry's "JavaScript Module Pattern: In-Depth", and he had some example code that I didn't quite understand. Under the Cross-File Private State heading, there is some example code ...
57
votes
9answers
19k views

Is browser fingerprinting a viable technique for identifying anonymous users?

Is browser fingerprinting a sufficient method for uniquely identifying anonymous users? What if you incorporate biometric data like mouse gestures or typing patterns? The other day I ran into the ...
6
votes
5answers
1k views

OOP private method parameters coding style

After coding for many years as a solo programmer, I have come to feel that most of the time there are many benefits to write private member functions with all of the used member variables included in ...
17
votes
6answers
44k views

How should data be passed between client-side Javascript and C# code behind an ASP.NET app?

I'm looking for the most efficient / standard way of passing data between client-side Javascript code and C# code behind an ASP.NET application. I've been using the following methods to achieve this ...
0
votes
2answers
3k views

A good tool for browser automation/client-side Web scripting [closed]

I'm interested in adopting a tool/scripting language to automate some daily tasks connected with fighting forum spammers. A brief overview of these tasks: analyze new registrations and posts on a ...
9
votes
4answers
294 views

Should I update blog posts or rewrite them as technology (and me) changes?

I started a programming blog earlier this year, and since I started it some things have changed. Some changes are due to technology changing, some changes are due to my code libraries improving, and ...
5
votes
5answers
521 views

How to properly shield a Product Owner from outside?

Update: We are a very small team (3 people) and thus I (Scrum Master) and the Product Owner are also developers doing some coding. We are aware of this situation and we are actively trying to ...
1
vote
2answers
93 views

Possibility Program for number of pieces

I would like to put a program together to calculate the number of 60' pieces would be needed from a list of shorter pieces. For example, I sell rebar cut to length from our standard length of 60'-0". ...
0
votes
2answers
632 views

How are interrupts implemented in practice? [closed]

Consider an USB device that is receiving data over a wireless network and an application running on the PC is reading this data. Now, on many languages (consider C# DataReceived), we have event ...
7
votes
4answers
1k views

Add an ID in every table even if it's not needed?

Is this good or bad design to add, by default, ID field in every table in a database, even when you don't see currently to usage of this ID (For instance in a MxN table) ?
9
votes
4answers
4k views

Increase Performance of VS 2010 by using a SSD [closed]

After searching on the internet for performance improvements when using Visual Studio 2010 with a solid state hard drive, I heard a lot of different opinions. A lot of people said that there isn't ...
4
votes
8answers
594 views

If you develop on multiple operating systems, is it better to have multiple computers + displays?

I develop for iOS and Linux. My preferred OS is Ubuntu. Now my software shop (me and a partner) is developing for Windows too. Now the question is, is it more efficient to have multiple workstations, ...
5
votes
1answer
914 views

How is the facade pattern different from abstraction layers?

I just read about the facade pattern and found this example where a client (user of a computer) invokes a startComputer() method which calls on all the complex stuff: Source: wikipedia /* Complex ...
10
votes
5answers
2k views

Is there any reason to use VARCHAR sizes rounded to a 128/256/4096 byte offset?

In database schema's, I often notice VARCHAR sizes are rounded to the byte offsets 128/256 or 4096. I've done it before as well, and the idea behind it was probably something with efficiency. ...
1
vote
1answer
124 views

Creating A Library That Requires Other Libraries (PHP)

Let's says that I am creating a PHP library that is using PHP 5.3 and namespaces and my library requires another library to work (this case it is the sfYaml library). I am trying to think of the best ...
-5
votes
2answers
3k views

What would be the prototype of printf?

look at these calls closely: printf("hello, world\n"); printf("%d", 2); printf("%d%g\n", 2, 2.3); we see that printf can accept any type and any number of args. however we know that functions in c ...
0
votes
6answers
2k views

Single Line Conditions and Loops - Best Practice [duplicate]

Possible Duplicate: Should curly braces appear on their own line? Which would be a better way to format single line loops and conditions in C Sharp if (i < j) { arr[i] = sum; } ...
19
votes
4answers
1k views

How to deal with checked exceptions that cannot ever be thrown

Example: foobar = new InputStreamReader(p.getInputStream(), "ISO-8859-1"); Since the encoding is hardcoded and correct, the constructor will never throw the UnsupportedEncodingException declared in ...
1
vote
4answers
1k views

How faster is an 'if' construct compared to an immediate 'if' statement (IIF) and when should I use it?

How does the traditional if statement compare with that of the immediate if statement (IIF, the one usually written as condition ? value_if_true : value_if_false) in terms of speed of execution? ...
31
votes
18answers
6k views

What would you do if your client required you not to use object-oriented programming?

I am writing a program to simulate the activity of ants in a grid (PDF). The ant can move around, pick up things and drop things. The problem is while the action of the ants and the positions of each ...
0
votes
2answers
153 views

Dissection of Google indexing services

There are more than a few questions that hop into mind when someone thinks about Google's indexing services. Jeff Atwood wrote about them at The Elephant in the Room: Google Monoculture and Trouble In ...
34
votes
8answers
3k views

What is the supposed productivity gain of dynamic typing?

I often heard the claim that dynamically typed languages are more productive than statically typed languages. What are the reasons for this claim? Isn't it just tooling with modern concepts like ...
6
votes
3answers
634 views

Why is scanf called scanf? (Same for printf.)

I am just curious why in the C programming language the function to read formatted input was called "scanf" as opposed to "readf". I assume it is derived from an earlier language, so in that case why ...
19
votes
13answers
6k views

What benefits are there to native JavaScript development?

Given how much simpler jQuery development is, when compared to native JavaScript, what makes people forgo libraries like jQuery altogether? Is this because jQuery has limitations or it is slow? I ...
10
votes
1answer
2k views

With PHP frameworks, why is the “route” concept used?

The reason I ask this is because isn't a PHP script a route? For example, if you have an article.php then your route is simply http://mysite.com/article.php. Why further abstract away the concept of ...
4
votes
1answer
603 views

Random pairing algorithm

If you have a list of items and you want to randomly pair the items in the list together, what kind of algorithm would you use to do that, such that the items can only be matched to one other item.
5
votes
2answers
800 views

Choosing a web development framework?

So, I've sort of reached a point where I want to start developing a website. Originally, I planned to build said website using PHP and CodeIgniter, I'm familiar with both, but, truth be told, I'm not ...
2
votes
1answer
760 views

Best Upper Bound & Best Lower Bound of an Algorithm

I am studying for a final exam and I came past a question I had on an earlier test. The questions asks us to find the minimum value in an unsorted array of integers. We must provide the best upper ...
1
vote
1answer
570 views

Can the Abstract Factory pattern be considered as a case of polymorphism?

I was looking for a pattern/solution that allows me call a method as a runtime exception in a group of different methods without using Reflection. I've recently become aware of the Abstract Factory ...
2
votes
1answer
313 views

What's the best way to organize JavaFX 2.0 code?

In every example I have seen yet almost all of the GUI code is written in the start(Stage stage) method of the main class. Is this the best approach, or is it OK to subclass the Stage class and make ...
11
votes
2answers
2k views

Why is Perl's smart-match operator considered broken?

I've seen a number of comments across the web Perl's smart-match operator is broken. I know it originally was part of Perl 6, then was implemented in Perl 5.10 off of an old version of the spec, and ...
37
votes
15answers
4k views

How can I convince cowboy programmers to use source control?

UPDATE I work on a small team of devs, 4 guys. They have all used source control. Most of them can't stand source control and instead choose not to use it. I strongly believe source control is a ...
0
votes
1answer
152 views

Multiple possible jsp views for a request

I'm looking to offer the user some way of changing how a single page looks based on some pre-defined jsps. i.e. Two or more jsp's contain similar information, and would be backed by a single ...
50
votes
11answers
3k views

Good, simple reasons for having multiple environments

Throughout my career I had worked at companies that had a collection of different environments for different purposes. We always had more or less our desktop environment, a test environment, a QA ...
58
votes
5answers
10k views

Clang warning flags for Objective-C development

As a C & Objective-C programmer, I'm a bit paranoid with the compiler warning flags. I usually try to find a complete list of warning flags for the compiler I use, and turn most of them on, unless ...
0
votes
1answer
1k views

iOS Guidelines for Free vs. Paid apps

A few months back, I was doing some recreational reading at the iOS Dev Center, and I came across a small list of guidelines for free vs. paid apps. It included guidance along these lines: How not ...
3
votes
3answers
1k views

How does a website like Mathway work?

I recently found a website called Mathway Basically, it works by allowing you to choose your "level of math" (which it uses to determine what tools it should provide to you) and then allows you to ...
8
votes
9answers
394 views

Are there any resources on how to identify problems that could best be solved with templates?

I decided to improve my knowledge in template meta-programming. I know the syntax and rules and been playing with counteless examples from online resources. I understand how powerful templates can be ...
2
votes
5answers
258 views

What's the key innovation in the realization of the “cloud?”

I'm trying to figure out what are the key technological innovations or inventions that the "cloud" introduces as an improvement over web pages; or maybe over SAAS. Seems to me that "cloud" is merely ...
5
votes
1answer
888 views

What's cool about Lisp nowadays? [duplicate]

Possible Duplicates: Why is Lisp useful? Is LISP still useful in today's world? Which version is most used? First of all, let me clarify: I'm aware of Lisp's place in history, as well ...
9
votes
4answers
620 views

What do neglected O'Reilly book topics tell us about that topic?

Does anybody know how O'Reilly chooses topics to publish? For some reason, I don't see how it can be based on demand. The reason, I ask, is because they haven't published a Delphi book in almost 12 ...
4
votes
4answers
1k views

Are there any GUI or user interface design patterns? [closed]

I was curious about GUI design patterns, so I searched and got some information, including a list of UI patterns for the web. This UI patterns website says that: UI Patterns is a growing ...
1
vote
4answers
390 views

Why high-tech OSs (like UNIX family) are mostly command based (rather than GUI based)? [closed]

DR-DOS, Plan, BSD, Sun Solaris, HP/UX, OpenServer.....and so on. Why high-tech OSs (like UNIX family) are mostly command based (rather than GUI based)?
3
votes
3answers
125 views

migrating product and team from startup race to quality development [duplicate]

Possible Duplicate: A simple ways to improve the release quality in RAD environment This is year 3 and product is selling good enough. Now we need to enforce good software development ...
26
votes
15answers
2k views

How to interview a natural scientist for a dev position?

Original Question I already did some interviews for my company, mostly computer scientists for dev positions but also some testers and project managers. Now I have to fill a vacancy in our research ...
1
vote
2answers
179 views

Backward compatibility with event-sourcing

How do you stay backward compatible with event-sourcing? Let say you release a version that has one kind of event, let call it X. You know how to handle that event in all the systems that extracts the ...
0
votes
2answers
238 views

Where can I get a definition of how the code is laid out in VB.NET 2010?

I am just starting out learning Visual Basic 2010. I have books and videos. The books all seem to be written for people who have some programming experience, even the books that say they are for ...

15 30 50 per page