language-agnostic

Are there any good / interesting analogs to regular expressions in 2d?

Are there any good (or at least interesting but flawed) analogs to regular expressions in two dimensions? In one dimension I can write something like /aaac?(bc)*b?aaa/ to quickly pull out a region of alternating bs and cs with a border of at least three as. Perhaps as importantly, I can come back a month later and see at a glance what ...

Balance of personalities in a Dev team

I am sure many of us have worked in teams where the teams have a different balance of personalities. Generally I think that having a diverse team is good. If people are too alike they tend to make the same mistakes. Some teams I have worked in have gelled well and worked well together, other times it has been very fraught. I couldn't eas...

Determine the name of the local Administrators group in Vista

How can I determine the name of the local Administrators group in Vista? This can vary depending on the operating system language. ...

What's The Best Approach To Do Keyword Searching On A Text Field?

I have a database table which holds meta data about images, the field in concern is the caption field. I want users to be able to enter keywords into a textbox and have the app return a selection of images that match the keywords based on their caption. I already have the code that returns an array of the individual keywords entered by ...

Future of languages with no standard and no corporate backing

Over the years we have seen (well, I have :) a number of languages come and go. Some were more accepted, some a little less. So I was wondering, what do you think are factors which most impact whether the language survives ? And whether it will have a future for a number of years (by that I mean several decades or so) ? For example, for...

What is the preferred method for handling unexpected enum values?

Suppose we have a method that accepts a value of an enumeration. After this method checks that the value is valid, it switches over the possible values. So the question is, what is the preferred method of handling unexpected values after the value range has been validated? For example: enum Mood { Happy, Sad } public void PrintMood(Mo...

What are unsigned variables?

I have seen this mentioned a lot but I have never figured out what it meant. Can anyone help me out? ...

Is my reputation system secure?

BOUNTY: To get bounty either show me how to play the system, or explain why you think it's impossible to play it. I'm developing a reputation system for a site that allows you to start your own blog of sorts, and to comment and have favorites etc. I aim for a very short ruleset that is easy to understand for the users and can't be "pla...

Variable Naming Conventions For Maps / Lists

I am getting into Groovy language, which has dynamic typing (as well as optional static typing). It also has native support for Lists, Maps, and Ranges, so I find myself using lists and maps a lot, especially lists of lists, lists of maps, maps of lists, etc. In static languages (esp with Generics) you always have an idea of what yo...

What is an easy way to explain how Garbage Collection works?

I have a short attention span so I couldn't make my way through the Wikipedia article. I understand there are several techniques for garbage collection but a common one is the "reachability" test, where an object's eligibility for collection is based on whether or not it can be "reached" by a rooted object (which, to my understanding is...

Phonetically Memorable Password Generation Algorithms

Background While at the Gym the other day, I was working with my combination lock, and realized something that would be useful to me as a programmer. To wit, my combination is three seperate sets of numbers that either sound alike, or have some other relation that makes them easy to remember. For instance, 5-15-25, 7-17-2, 6-24-5. The...

Is using the directory separator constant neccessary?

I am using PHP, but I guess this question might be language agnostic. With PHP, a constant is defined by PHP, called DIRECTORY_SEPARATOR. I have seen this in Joomla define('DS', DIRECTORY_SEPARATOR); // quicker to type plus DS is easier to read in a path I thought this looked like a good idea so I incorporated it into some of my sit...

How do recommendation systems work?

I've always been curious as to how these systems work. For example, how do netflix or Amazon determine what recommendations to make based on past purchases and/or ratings? Are there any algorithms to read up on? Just so there's no misperceptions here, there's no practical reason for me asking. I'm just asking out of sheer curiosity. ...

What's it like to work in a large programming team?

I've always felt lucky to work in a small programming team. I think the most I've worked with is 11 programmers. What is it like working on a project with hundreds of developers? Thousands? What does scale and what doesn't? EDIT: Thanks for all the responses! There seem to be very few positives: possible to work on mega-large codeb...

Do you think natively compiled languages have reached their EOL?

If we look at the major programming languages in use today it is pretty noticeable that the vast majority of them are, in fact, interpreted. Looking at the largest piece of the pie we have Java and C# which are both enterprise-ready, heavy-duty, serious programming languages which are basically compiled to byte-code only to be interpret...

Have you ever had a business requirement that turned out to be an NP-Complete problem?

NP-completeness seems to me like one of those things that's mostly just theoretical and not really something you'd run into in a normal work environment. So I'm kind of curious if anyone's ever run into a problem at their job that turned out to be NP-complete, and that the design needed to be changed to accommodate for it? ...

When NOT to use garbage collection?

The obvious cases for not using garbage collection are hard realtime, severely limited memory, and wanting to do bit twiddling with pointers. Are there any other, less discussed, good reasons why someone would prefer manual memory management instead of GC? ...

What is the most important attribute of a project manager/team leader you expect?

Just read Joel on Software - How to be a program manager. In his article he points out different things for a program manager. ...(in fact, with 14 years of programming experience, you might know too much to be a good user advocate ...earn the respect of the programmers so that they concede that you’re right ...It helps, as...

Is it reasonable to have more than 65536 User Defined Types in large projects?

I'm thinking about some stuff related to runtime type info, and I'd like some feedback from programmers who work on much larger projects than I do. Is it at all reasonable to expect any program to ever have more than 65536 (2^16) user-defined types (classes and structs) in a single project? This does not mean 65536 instances, it means ...

How to detect device on network?

Some printers include a CD which is able to detect a device without an IP address assigned or with an invalid IP in the LAN. We are developing an appliance whishing to be able for the user act in the same way: they connect the appliance on network and from the client side a tiny software detects configuration, launch wizard, ... How ca...