Source code is any collection of computer instructions (possibly with comments) written using some human-readable computer language, usually as text.

learn more… | top users | synonyms (1)

4
votes
2answers
900 views

Writing recursive functions

I am having a lot of trouble writing recursive functions related to trees. I can't just use google for these functions as they are not general and I won't be able to use google in an exam setting! Is ...
4
votes
3answers
142 views

Is there a difference between the quotes in `help',``help“, 'help' and ”help"?

Sometimes I find in the source code files comments have quotation marks like these ,notice the ` : `help' ``help" For example, these are comments from GNU cat source code file, cat.c: /* Plain ...
21
votes
5answers
995 views

How-to convince company to start documenting for legacy software [duplicate]

It has been less than a year since I joined my current company. Their majority of sales have come from a single product that has been alive since the last 10 years. However, there is minimal (if at ...
21
votes
7answers
1k views

In a legacy codebase, how do I quickly find out what is being used and what isn't?

I've been asked to evaluate what appears to be a substantial legacy codebase, as a precursor to taking a contract maintaining that codebase. This isn't the first time I've been in this situation. In ...
5
votes
7answers
292 views

What should be the “depth of design”? [closed]

We all know that the process of creating a design and the whole architecture of the software is very important before writing the code. But how deep should be dive into the design stuff - should we ...
1
vote
1answer
243 views

How to quantify benefits from a programming training?

I'm conducting a programming training for 3 months. Details in this link - Programming Training Details. My question is "How do we quantify benefits from such training?". I think the two important ...
7
votes
2answers
529 views

Are there any opensource APIs that help analyze code?

As an example, let's say that I need to check for a certain usage of C# code and warn the user that that is a bad pratice. There are multiple usages that I want to detect, such as: Resource not ...
5
votes
3answers
6k views

How do I encrypt the source code on the webserver?

I have a web application developed using Python, HTML, CSS & JavaScript. The customer installs it in any of their own Machine and uses it through their LAN. In short the customer sets up the ...
1
vote
5answers
162 views

Automatic sorting of class/module members and its possible impact on productivity and code quality

Recently I saw some possibilities of some IDEs (via plugins) to sort members of their classes/modules based on some criteria, sou you could have everything sorted automaticaly no matter where you ...
5
votes
5answers
1k views

Example bad code project to motivate refactoring / good design [closed]

This is sort of the opposite of Is there an open-source project that can be an example of well-written code?. I am teaching software engineering to undergraduates and I would like a blob of object ...
1
vote
2answers
172 views

Does slicing a design in PS create horrible CSS?

I am a beginning programmer and I really want to have good habits and practices. I have yet to slice up a PSD and code it. Is this a bad practice? I have heard it creates bad code that had to be ...
5
votes
9answers
5k views

Reading source code to learn

As you develop as a programmer, software developer, or coder, IMHO, you begin to see different (best or worst) practices, different algorithms, and "more than one way to do it". Seeing this code can ...
4
votes
1answer
679 views

Include all php files in one file and include that file in every page if we're using hiphop?

I understand that in normal php if we're including a file we're merging the source of it in the script and it would take longer for that page to be parsed/processed but if we're using HipHop shouldn't ...
14
votes
10answers
2k views

About empty line of code

Why do my colleagues hate it when I add an empty line of code? Sometimes I add a few lines to see when a method ends and another one starts more easily.
2
votes
2answers
887 views

Use Google Analytics to track visitor/download stats for a Google Code Project?

Can you use Google Analytics to track visitors/downloaders for a Google Code project? I've searched google for an answer but I get results about Google Analytics as a Google Code project itself and ...
2
votes
6answers
686 views

Shouldn't we count characters of code and comments instead of lines of code and comments? [closed]

Counting lines of code and comments is sometimes bogus, since most of what we write may be written in one or more lines, depending column count limitations, screen size, style and so forth. Since the ...
7
votes
4answers
521 views

Is coding and unit testing violating the DRY principle

The dry principle states: "Every piece of knowledge must have a single, unambiguous, authoritative representation within a system." However when writing tests for code you are describing the ...
4
votes
1answer
221 views

Redundant code ok?

Using C#/.Net, I have a page where the user can enter data and save these data by clicking a button. To save data, the user needs to enter a valid date, this means a date which has a certain format. ...
23
votes
9answers
2k views

How should I go about learning a very large and complex application? [duplicate]

Being a young and fairly inexperienced developer recently employed by a "real" software company I'd like some opinions and pointers on how to do the following: Approaches on how to get familiar with ...
9
votes
3answers
239 views

When would be the best time to start porting the code of my own project?

If I have a personal programming project that I plan to port in another language so it could run in other environments, would it be more ideal to start porting the code as soon as possible and work on ...
6
votes
7answers
1k views

How to cope with the problem of (compiling) a large code base?

Although I can code, I don't yet have any experience with working on large projects. What I did so far was either coding small programs that get compiled in matter of seconds (various c/c++ exercises ...
6
votes
3answers
378 views

Detecting Internet code leaks

I'm curious after reading today about a minor code leakage from a large project to some blogs & forums (to say it short: the guys forgot to anonymize the code before asking for help), all detected ...
2
votes
4answers
1k views

How do I protect my website (Codes, Database, FTP informations) from freelancer?

I'm developing a website using Joomla and many other 3rd party plugins and also I want to make some custom components so I'm hiring some freelancer developers and few are an online companies they say ...
2
votes
6answers
1k views

Secure cloud based code storage and syncing across multiple computers [closed]

I've been thinking recently about how and where I keep my code - I work across multiple locations, with at least three different computers and I'm considering how I manage my code across these ...
6
votes
5answers
2k views

Why do programmers use one-based indexing for line numbers in source code? [duplicate]

Possible Duplicate: Why isn't the line count in Visual Studio zero-based? Why isn't the top line in a source code file labelled line number 0? i.e. in a source file which was 10 ...
3
votes
2answers
1k views

Outsourcing: question about code ownership and copyright

I want to ask a question from an employer point of view. I know that you are not really lawyers and stuff but I think you might help. I'm into negotiations with a freelancer (from India) to create a ...
48
votes
13answers
3k views

*Code owner* system: is it an efficient way?

There is a new developer in our team. An agile methodology is in use at our company. But the developer has another experience: he considers that particular parts of the code must be assigned to ...
12
votes
2answers
12k views

How do you change how intellij auto formats code?

IntelliJ does some odd formatting with Javascript code and I am trying to figure out how to get it to stop formatting this way. Whenever I chain jQuery functions together, it over indents the auto ...
7
votes
6answers
691 views

“Anything can go wrong will go wrong” - Murphy's Law. so is it necessary to test all the conditional, exception cases?

If "Anything can go wrong will go wrong" is true, we need to test all the conditionals and exceptional cases in my code. But sometimes it's hard to find all of them since many of them are corner ...
7
votes
4answers
146 views

Are there revision repositories which implement commenting on revisions other than a fixed single commit message? [closed]

Sangdol asked: Why can’t I edit and SVN commit message? There are good reasons to maintain individual records ‘as is’ for historical purposes. However, there is an arguably objective hazard in not ...
7
votes
3answers
400 views

How do you find your way in deeply nested, interfacey code? [duplicate]

I know most people hate flat and long functions, and hate when code is not full of ISomethings. The problem is that I guess my mind works in different way, and I always have problems with that type ...
3
votes
3answers
198 views

Supplying code to people helping you debug?

I was wondering if it is wise or advisable to send over a large amount of source code of one's application for debugging and error solving purposes, I'm working on an iOS app that I hope to release to ...
20
votes
4answers
7k views

Classes naming: singular or plural?

It is always difficult for me to choose between singular and plural forms for classes names: CustomerRepository vs. CustomersRepository CustomerService vs. CustomersService CustomerController vs. ...
7
votes
3answers
375 views

How can I start shipping code?

I have just started learning how to program using LPTHW, and as my skill level develops I would like to start shipping code whether or not it's ready to be shipped, just to get into the habit of ...
3
votes
4answers
1k views

source code check in / validation best practices

I am looking for best practices that big organizations follow for code check-in and validations. Currently we follow these steps, - Developer writes code - Developer do some initial tests - Code is ...
36
votes
14answers
3k views

Do you sign each of your source files with your name? [duplicate]

Possible Duplicate: How do you keep track of the authors of code? One of my colleagues is in the habit of putting his name and email address in the head of each source file he works on, as ...
7
votes
6answers
1k views

Multiple inheritance use cases

Java omits multiple inheritance on the grounds that it obviates the design goal of keeping the language simple. I wonder if Java (with its eco-system) is really "simple". Python is not complex and ...
1
vote
1answer
251 views

Store build server configuration in same repository as source code?

Some co-workers and myself are tasked with a "rewrite" of an ancient, unmaintainable application and to shape it into something workable. I am setting up a continuous integration server, and since we ...
17
votes
5answers
4k views

How do I understand an open source project code?

I open the source code and it's folder upon folder of infinite files each with infinite lines of code which doesn't make much sense to me because I dont have the context, and half of it uses functions ...
3
votes
3answers
290 views

When you create an open source project, how to know who's participating and if his version is good?

my friend has developed a CAD program in C, here it is http://web2coders.jrcw3.com/ i have convinced him to go open source, but we have some concerns: if you upload a project to sourceforge or ...
8
votes
4answers
712 views

Is integer used too much as a data type?

Do most application developers use signed integers in places where they really mean to use unsigned integers? I do it all the time, so do my co-workers. I haven't seen a lot of other extensive ...
53
votes
10answers
8k views

When is code “legacy”? [closed]

We've all done it, we've labelled some code (often stuff we've inherited) as "legacy"? But it's still used in the production systems - so is it really legacy? And what makes it legacy? Should we shy ...
0
votes
5answers
436 views

Hiring Developers - Securing Source Code [duplicate]

I have a popular web-based app, and now suddenly my main developer has disappeared. Although I've found other great developers but I don't want to distribute the source code to everyone. Is there any ...
4
votes
5answers
494 views

View Source - is the Viewable markup important to you?

I just read a very compelling blog post from Scott Hanselman where he quoted colleague Erik Meijer as follows: JavaScript is an assembly language. The JavaScript + HTML generate is like a .NET ...
6
votes
1answer
3k views

Virus source code [closed]

Recently I read an article on the bbc about encrypted viruses. I have no idea about how one would even start programming something like that. I would love to see the source code for that or something ...
5
votes
4answers
335 views

What can I gain from examining others code?

I recently downloaded some large code bases and have had light reads through them, but what can I gain from this? How can I be sure what the author is doing is the right way to go about things? (One ...
6
votes
3answers
958 views

Is collective code ownership mandatory in Scrum?

Is is an absolute must when following the Scrum methodology to practice collective code ownership, instead of for example weak code ownership?
0
votes
4answers
208 views

Deciphering foreign code [duplicate]

What is the best strategy to go about understanding some one else's code for a medium sized project, if the code is not well documented and does not adhere to many coding standards?
1
vote
4answers
222 views

API naming and namespacing

Is it right or more beautiful to name the functions with an prefix, like in Qt? Or using "many" namespaces, but 'normal' names for functions? For example, slOpenFile(); //"sl" means "some lib" vs ...
214
votes
15answers
24k views

How can a code editor effectively hint at code nesting level - without using indentation?

I've written an XML text editor that provides 2 view options for the same XML text, one indented (virtually), the other left-justified. The motivation for the left-justified view is to help users ...