instruction
stringlengths
34
36.1k
I was wondering what the general best practice is for when you have multiple unit test fixtures testing different things that use the same file paths. My test files are in a directory tree with certain rules so currently I am reusing directory macros in each file, i.e. #define TYPE1FILE "Type1Files/" #define TYPE2FILE ...
(I think the problem described below is also affecting VS although I only tested it in MD) I have some trouble regarding circular dependencies. I know they are bad practice and should be avoided. In recent MonoDevelop Releases, you can't even create circular dependencies. However, I can't find an easy way out in the fo...
Back in 2007, I read an article about Joshua Blochs take on the "builder pattern" and how it could be modified to improve the overuse of constructors and setters, especially when an object has a large number of properties, most of which are optional. A brief summary of this design pattern is articled here. I liked the ...
Is it viable to charge for an open-source product? Both legally and financially, it seems like a very strange thing to do. However, I keep hearing people say that it's possible. Are there even any real-world examples for this sort of thing?
So I have been reading Inside the Machine by Jon Stokes. It is a FANTASTIC book, and it has got me thinking about the effects of programming on processors... Given a branch unit in a CPU and a complex conditional statement that involves a procedure call (If IsTodayAHoliday( Now ) > 0 Then), is it faster to stick the re...
I have recently moved to a VIM environment for Python development. I learned the setup from John Anderson's outstanding web page on the subject. I am about to try and set up another VIM environment for C++. Is this even possible to do effectively? Or should I really have two accounts on my Linux box, one for Python...
So much of development is now done online to take advantage of interconnectivity and shared resources. In a prolonged Internet outage, how can one cope with the lack of that connection? Are there ways to replicate or work around the innumerable benefits the Internet adds to development?
I am mostly developing on ASP.NET MVC and sometimes on ASP.NET WebForms. But when I hit a PHP web site, I always think that; Should I learn PHP? Assuming answer here is yes, where would be the first place to start and where should I go from there?
This may be a noob question but a colleague and I are working on a project. Some background about our situation is: We control versions using a centralized git server inside our office. We code in PHP, so we try our code offline in a local apache instance. We use local MySQL instances at work. Our client is a bit of ...
There are three scenarios where I am asked to predict how long it will take: I know I can solve the problem without further consultation of anything (that is, there is no unknown in the problem. I already have all the knowledge to solve the problem) I know the problem can be solved but I need to do a lot of e...
I want to create a clone of a Google Code repository, which I cannot download due to Country restrictions and I want to migrate that clone into Github, which I can use without any problem. The thing is I have a Github account and I can browse through GoogleCode but I cannot take my TortoiseHg and clone a repo just lik...
An intern will be starting with us soon for a couple months before going off to university. The intern is straight-out of high school and has some programming experience, but has never taken a university level computer science course or held a programming job. In addition, the intern has never used 99 percent of the ...
I am from the UK. I have about 4 years experience working for a large European IT outsourcing company. This company was split into two; professional service and managed service. I only worked in the managed services and there was a lot of resources issues concerning reaching customer's expectation and there was a lot o...
I'm starting up a Git repository for a group project. Does it make sense to store documents in the same Git repository as code - it seems like this conflicts with the nature of the git revision flow. Here is a summary of my question(s): Is the Git revisioning style going to be confusing if both code and documents are ...
What is the best way to develop and maintain legacy code not in version control? Adding it to version control is of course the obvious answer, but if you can't, for some reason, what would you do? A few reasons I can think of why version control wouldn't be possible are: Management is against it (doesn't understand it...
I am developing an application in Flex. There are 20+ 'pages', each with its own form. I need to collect all the entered data and pass it to an API method. What I am wondering is when I should begin to pass the data and what the best way to collect it might be. I was thinking of instantiating a class public class myCol...
We're currently interviewing few candidates for an internship, which is a really new experience for us as a company and for me personally as a team lead/manager. What would be the most effective and useful, yet fun approach for both sides here? How do we 'integrate' an intern into our development team and workflow wit...
I'm new to c++ and I wanted to know few questions regarding makefile. 1) Is writing makefile really important ? I mean there are many IDE's which does this automatically. Also, do people in programming job write makefiles or do they use automation? 2) Should I learn GNU make or something else like cmake or other ? Can ...
As you might have noticed from the title, this is not a "PHP or Ruby", or a "PHP vs. Ruby" question. This is a question on how to leverage PHP + Ruby in the same business. I myself am a PHP developer, I love the language because of its convenience and I specially love the ecosystem of resources that surround it: Joomla...
Currently, I'm a student and I can tackle all my assignments which only require, at most, 3-5 classes to implement. Now, I'm wanting to develop programs on a bigger scale but I am having a really difficult time figuring out how to design the program from a higher level. The real world example I am working on is a grou...
I am writing an application that will crawl web pages and analyze data, and I'm wondering if I can host this as a cloud-based service. The main reason I'm looking at cloud hosting is that users may process thousands of pages at once, and I need to return data as quickly as possible. The user will have software installe...
Is it OK if, within a team, developers use different flavors of SVN? Say one using Tortoise SVN and other using Versionsapp.com SVN?
Does anybody know how secure are my private repositories on bitbucket.org? Can I rely on that? I have some repositories and I only want them to be reachable only by me and two others.
What is the meaning of platform independence? I am taking the case of Java. Can I run a Java application on Linux that built on Windows platform? Or the reverse? Can I use a same (or exact) programming algorithm on both operating systems? In my view File Types are platform independent like Videos, Images, Documents etc...
I currently use one controller per action. One of the problems—sort of—I encountered is when naming the methods of these controllers, which only have one. Should I use a generic method name like get() or should I encapsulate all my controllers into one and name its methods after the action they do, e.g. indexAction(), ...
I have good teacher who understands OOP. However, the language which he is expert in is Java and I don't want to learn Java. My question is, do you think if I learn OOP using Java I will waste my time? And do you think it is good to start to learn OOP?
I've heard a lot about the advantages of doing less programming work in GUI apps and using more command-line tools (especially with regard to getting things done more efficiently). However, since I don't understand how my workflow would be different if I depended more on command-line tools, I can't readily evaluate wh...
This is something I've been thinking about ever since I read this answer in the controversial programming opinions thread: Your job is to put yourself out of work. When you're writing software for your employer, any software that you create is to be written in such a way that it can be picked up by any developer and u...
I have been working on making a completely offline dictionary using the Wiktionary XML dumps. The dumps themselves are about 10 MB, but when converted into a index using a search engine indexer (I use Whoosh Search Engine in Python), the complete index comes to about 250 MB. Which I think would be difficult to distribu...
I have just started my journey as a C++ developer, and I have recently been researching a topic called meta-programming. So far, I have gone through a lot of information on the topic, and have few questions. Usage of Reflection in c++: Is it possible? As per my understanding reflection is a meta-programming technique ...
I'm looking at using a few open source products in a commercial software application I'm working on. One of them is licensed under MIT, which I understand as allowing commercial software linking. However, the other open source product is licensed under MS-PL but I don't understand if that license is fully compatible ...
It's unfortunate, but I'm taking this course that would require me to work in Flash CS3 (specifically programming), which would make me use windows. I'm very used to development under Ubuntu, and booting into windows would require me to switch a hard drive. I was wondering if: I could use the Flex 4.5 SDK to develop (...
For an assignment, I have to find out which of the Gang of Four design pattern the classes java.io.Reader and its subclasses java.io.PushbackReader, java.io.BufferedReader and java.io.FilterReader were built with. According to this post, the design pattern would be the Decorator Pattern. This only makes sense to me if ...
I use interfaces rarely and find them common in others code. Also I create sub and super classes (while creating my own classes) rarely in my code. Is it a bad thing? Would you suggest changing this style? Does this style have any side-effects? Is this because I have not worked on any large projects?
I've written a decent chunk of code over the past few days and I'm ready to git init it and push it to github. But before I do so, I want to do this the "correct" way in case anyone else wants to use my code. So I guess I need to pick a license (probably MIT) and implement it, and write some sort of comment at the top ...
What are possible/standard words to describe your skill levels in different programming languages in your CV? I currently use these three: expert advanced beginner I do not consider myself an expert in any programming language, so I classify all my skills as either beginner or advanced. However, I would like to diffe...
Last couple of weeks I've been searching for some project management solution for a place where I work at the moment. There we rely on excel spreadsheets, but we meet limitations like access rights and concurrency (I have to work with a local copy of a spreadsheet and twice a day dump it to the main spreadsheet) and s...
From everything I have learned about "Aspect-Oriented Programming" or "Aspect-Oriented Software Development," labeling it as a programming paradigm or methodology appears to be inaccurate. From what I can tell it is not a fundamental technique for programming. To nail down what is meant by "paradigm" and "methodolog...
Some questions can be answered easily by using specific language library. For example Java has Set, Maps, and List. Is it possible to answer those coding questions during interview by using these library or should we go more with a traditional down to earth approach, making it a C- kind of answer?
The basic gist of most Agile methods is that a feature is not "done" until it's been developed, tested, and in many cases released. This is supposed to happen in quick turnaround chunks of time such as "Sprints" in the Scrum process. A common part of Agile is also TDD, which states that tests are done first. My team w...
Software development today isn't evidence-based. That is, we don't really choose technologies and practices based on the outcome of research studies the way (we hope!) they do in, say, medicine. As an example, there was a study published in early 2011 in the Journal of the American Medical Association that suggested r...
I have recently installed Visual Studio 2010. By default it has a nice layout, and when I open files, the tabbed windows for those files appear where I like them to appear: source code on the upper half of the screen, compiler output, test status, trace windows on the bottom half. But, after a period of using it, I f...
How do the big price comparison services allow to send emails directly if the price of a product meets your targeted price. They will email you automatically. Is it a cron job that scans a table, or is it something compounded into the database?
For testing and running some very intensive C++ number crunching applications, we need to apply for supercomputing time. I would like to get feedback and opinions from you; which calls do you follow, which supercomputing centers do you apply to, etc. As of now I only know DEISA in Europe.
Is there a practical reason to learn xhtml still? Should I learn to make my webpages in xhtml instead of html5 still or does it matter?
I want to know whether it is possible to develop desktop applications using the PHP language. In my case, I have never developed one with it. If it possible, please give me referral link or detailed understanding of where i can improve my skills.
I have seen C++ code such as the following with many typedefs. What are the benefits of using many typedefs like this as opposed to using C++ primitives? Is there another approach that might also achieve those benefits? In the end, the data is all stored in memory or transmitted over the wire as bits and bytes, does it...
My company is looking to improve their market research data management. Current data management style: "Hey Jimbo, where's that picture of our WhatZit 2.0? "yeah I remember that email about that company from that guy, gimme a few minutes to search my Outlook" "who has the newest copy of the Important Competitor's prod...
We're just about to start a new greenfield project - it's a highly functional web application using ASP.NET MVC3, SQL Server etc. We're also going to be using Windows Workflow Foundation for the first time. Our client only wants to use his existing Windows Server 2003 web servers. My main issue (other than it is 8 year...
Our site currently is going to require our users to download a player to view videos they will want to view on our site. The videos get uploaded by users from various sources (smartphones in 3gp format for example). However most people have Flash on their machines. I am trying to 'make a gentle stand' and tell the te...
Overview I’m going to develop an app on Android and iOS. It will allow users to set up group ‘chat rooms’ and talk on chat rooms set up by other users. The service needs to be highly scalable, such that it could accommodate a massive increase in users overnight (we can only dream). Background info Previously I've used...
Can anybody tell me how I can give my paid app a free download option to one of my friend from iTunes Connect. What I mean is that I will give my friend a code by which he can download my app without paying. Can anyone tell me if there is any option in iTunes Connect to do this?
I have been a consultant for a small software consulting firm for quite some time now. Our normal business model is not staff augmentation, but such that we find clients who need assistance in building a solution of some kind and then send in a team who can build that solution, work with the existing IT staff, train a...
What tools / methodologies / strategies do you use to keep organized in doing your work as a developer? Can you provide details?
Currently I wish to expand my professional skills with Bachelor degree. However, I am not able to study full time abroad, but looking for University where I could study in distance (online from home), coming just several times in a semester to the University to pass exams, complete papers and so on. I am looking for So...
I'm a self-taught programmer. I am honestly not good in math. What advice you can give to improve my Mathematical skills so that I will not be so insecure around my fellow programmers? What are the steps or guidelines that you can recommend to improve my mathematical skills? Is there a book out there that's the de-fact...
Question : Is the science and art of CS dead? By that I mean, the real requirements to think, plan and efficiently solve problems seems to be falling away from CS these days. The field seems to be lowering the entry-barrier so more people can 'program' without having to learn how to truly program. Background : I'm a re...
I'm currently trying to decide what server-side language to learn and use for web development, and while it's relatively easy to get information on why x, y, or z is a good thing, it's harder to figure out the downsides to each of them. In particular, I'm curious about what drawbacks there are to learning and/or using...
There are some job requirements of project management experience for a programmer, such as: the candidate has to have some experience managing a project, not necessarily with subordinates, but rather having worked on a project all the way from design down to test. I was wondering what "subordinates" mean he...
Which one of these is the easiest/fastest choice for developing simple Android apps/games? I'm familiar with all this technologies. • Android SDK or NDK • C# on MonoDroid platform • Adobe Flash & Adobe AIR • Corona SDK • Converting tools like PhoneGap Fundamentally, Could you explain adventages and disa...
I was listening to The Servile State by Hilare Belloc this morning and pondering whether or not I possessed the means of production, as did the peasant of the Middle Ages; as did not his descendants after the oligarchs of England forced him into servitude. The means of production was the arable land that the serf was s...
Possible Duplicate: Version control for independent developers? I was wondering if there is a tool out there which acts as Visual Source Safe but only on local machine. Basically I would like to check in and check out on my local machine when I am codeing on my personal project from home.
In some colleges students are let to use an IDE and Internet and in mine you have to write down your solution in paper. As far as I know, it's pretty much impossible to make a correct non-trivial program on the first try. I'd be fine with no using computers if my teachers assessed my approach instead my code -literally...
The firm I work at keeps a copy of the compiled source code on production. So basically on our Production server, we have two folders: ProductionServer\SourceCode\ ProductionServer\SourceCodeRollback\ The Rollback folder always contains one version older code. This is done so that on deployment nights, if something i...
I've been programming for over 9 years, and according to the advice of my first programming teacher, I always keep my main() function extremely short. At first I had no idea why. I just obeyed without understanding, much to the delight of my professors. After gaining experience, I realized that if I designed my code co...
I never learnt anything about VB6 (and I dont want to) but I wanted to search for bad things in computer software, so my first though was VB6. So for example, VB6 was strongly typed with late binding. Makes some sense to have a language with that combination? (I dont think so). I want to know reasons of why VB6 was lik...
I'm looking for feedback on MVP and MVC patterns used as a framework to build a website. I've used both with a certain degrees of success and failure. Furthermore I've worked in places which have miserable implement MVP across the web, desktop and services layers. I've also seen a few terrible MVC implementations. One ...
I wrote a really cool bookmarklet and now I want to tell everyone. I have absolutely no idea where to go, is there some sort of exchange for these things? In case anyone is curious: I was tired of having to retype URLs from my desktop browser on to my phone browser, with its itsy-bitsy keyboard, so I wrote a bookmarkl...
My target platform is Mac OS X, but I'm looking for a library that will give me a 2D coordinate of someone's head, via the built in webcam. My requirements are that it be near real time if not real time, give me a 2d screen coordinate I can write out to a log.
I've been programming in procedural languages for quite some time now, and my first reaction to a problem is to start breaking it down into tasks to perform rather than to consider the different entities (objects) that exist and their relationships. I have had a university course in OOP, and understand the fundamentals...
My plan is to develop a web based application in the future. I think I can name it "Booth Reservation System" for the Events companies here in our country. One of the main functionality of the system and the most tricky part/difficult part is that the user can upload a "floor plan" (the design of the area were the boot...
So it's kinda weird asking two questions back-to-back, but they aren't very related and I didn't want to combine them, but I'm not spamming questions, I promise! Anyway, I'm a recent college grad, and my education only touched on design patterns...we implemented a few simple ones, touched on the fact that there were mo...
I am considering using GridSQL in a production environment. However, I do have some indications that it is not ready. One is that it got excluded by the offering of EnterpriseDB a while ago, and the forums seem to report a few wrong results and relatively severe bugs. The alternatives to GridSQL, however cost around 10...
According to a popular SO post is it considered a bad practice to prefix table names. At my company every column is prefixed by a table name. This is difficult for me to read. I'm not sure the reason, but this naming is actually the company standard. I can't stand the naming convention, but I have no documentation t...
We are building a product for Procurement Domain in JAVA. Following are the main technical requirements. Platform Independent Database Independent Browser Independent In functional requirements the product is very dynamic in nature. The main reason being the procurement process around the world is different from cli...
When tuning performance in a web application, I am looking for good and light-weight performance profiling tools to measure the execution time for each method. I know that the easiest profiling method is to log the start time and end time for each method, but I see more and more people using AOP to profile (add @profil...
Does the single responsibility principal promote flexibility? If not what are the other methods to make your classes more flexible? By flexibility I mean, a class is able to function correctly at any time with little (or even with no) hassle.
I would like to release some code and some documentation to be distributed freely, but not if it has been modified in any way. Basically, needs to be shared "as-is". The reason is I would like to retain control of all modifications without making it it closed source. Is there a commonly available license that allows fo...
Is CodeIgniter is recommended for a large web based ERP or Business Application? I want to use CodeIgniter for my future Project and I'm so confused whether to use it or not. Im so worried about in the long term process or lifetime of the application that it may crashed or produce a bug or error. I also worried about t...
When would you keep simple to medium-complex personal calculations in a spread sheet (Excel etc) and when would you write a small program or script for it? For example when you want to calculate what size of mortgage you can afford to buy a house. I could create a spreadsheet and have a nice tabular representation. On ...
I remember a few years back, when I had a web-site I wanted to develop, that many people recommended I go the LAMP route. Unfortunately, I never got around to studying/practicing that. I'm currently revisiting the web-site idea. The web-site will be dynamic, transactional, and hopefully end up with around 1,000,000 p...
A random person on the internet told me that a technology was secure(1), safe to use and didn't contain keyloggers because it is open source. While I can trivially detect the key stroke logger in this open source application, what can developers(2) do to protect themselves against rouge committers to open source proje...
I heard about some big companies e.g. Google, Facebook use Perforce Are there any reason why SVN/Git cannot replace Perforce?
I received a code review from a senior developer today asking "By the way, what is your objection to dispatching functions by way of a switch statement?" I have read in many places about how pumping an argument through switch to call methods is bad OOP, not as extensible, etc. However, I can't really come up with a d...
I want to learn to program in a 'future-proof' manner, if you like. Whilst Windows dominates the desktop OS marketplace (for now), obviously there is a lot of value in learning its languages/frameworks/API's and so on - this might be subject to change as new devices emerge or Windows shoots itself in the foot (over-fri...
I've been a solo .NET programmer for a small startup for the last 8 years. I've put together some pretty decent software, and I always strived to better myself and conform to best practices, including source control (SVN/TFS). I worked very closely with a team of engineers of other disciplines, but when it came down to...
While browsing SO today I found this question here and it starts with this: Sure, you're gonna tell me that SOAP is depracated and all, well i'm forced to use it Found lots of statement like this one on SO up till now, this one just triggered me to ask this question. REST has its uses, SOAP has its uses, in some plac...
Performance reviews have come up recently at my work, and I was put in an interesting position. Our team does a lot of pair programming, which has a tendency of averaging out the skill differences between team members (especially considering we rotate pairs). Generally, when doing performance reviews, you look back at ...
I do a lot of Java programming at my work (I'm an intern) and I was wondering if it is generally a rule to create javadoc to accompany my code. I usually document every method and class anyways, but I find it hard to adhere to Javadoc's syntax (writing down the variables and the output so that the parser can generate h...
I'm an intern working for a company for the summer. I've been warmly received and I manage to impress my manager a lot (I guess I'm more experienced than the other people he interviewed). Recently I've been developing a kiosk type application which will generate a simple GUI menu from a text config file a 4 year old co...
I've seen on my work place (a University) most students making the software estimation cost of their final diploma work using COCOMO. My guessing is that this way of estimating costs is somewhat old (COCOMO dates of 1981), hence my question: How do you estimate costs in your software? I've seen things like : Cost = ( ...
I'm an inexperienced student (having learned up to data structures and algorithms through various online resources) of computer science, and I'm hoping to get a job as a developer some time after I've gotten a few independent projects done. My question is, how should I choose which projects to work on? I've been looki...
I am working for a company as a web dev consultant at the moment, and they asked me whether I want to get payed through the Umbrella company or through my Ltd. Which is better for me and why? The @David Thornley made a good point in comments. Don't forget that we are talking about web developing here. I am not sure how...
I see a lot of crap online about how Erlang kicks node.js' ass in just about every conceivable category. So I'd like to learn Erlang, and give it a shot, but here's the problem. I'm finding that I have a much harder time picking up Erlang than I did picking up node.js. With node.js, I could pick a relatively complex p...
Today, Firefox 5 was released. If all goes according to plan, Firefox 7 will be out by the end of the year. Firefox has adopted the Google Chrome development model wherein version numbers are largely unimportant and so just supporting "the latest (publicly available) one" is probably the best strategy. But how do you b...
here is my main question: What is the most common way that Java is used in web development? The reason I ask: I am currently in the process of finding my first internship. Every employer has a separate set of languages, technologies and acronyms they want their candidates to know. In school I did well with Java. As ...
After learning JavaScript syntax, what are some good resources for learning about integrating JavaScript with other languages (HTML, XML, CSS, PHP) to create real, useful applications? I'm most interested in reading articles or other people's code - not so interested in books. Basically, I'm looking to move from progra...
My Comcast DVR takes at least three seconds to respond to every remote control keypress, making the simple task of watching television into a frustrating button-mashing experience. My iPhone takes at least fifteen seconds to display text messages and crashes ¼ of the times I try to bring up the iPod app; simply receivi...
Given an iPad, iPhone, Playbook, or other mobile device, what SCM tasks make sense on these devices. Code review? Change propagation between branches? Automated build results after check in? What else? Code generation? Debugging? Code editing in the cloud? Or do you think all SCM tasks will always be performed on a d...
People used to say it's "better"/"Make more money" to do back-end programming (PHP, asp.net) instead of front-end(HTML, javascript) for web development. But I notice that HTML5, CSS3, WebGL, Javascript are gaining importance. We can even use HTML5, CSS3 and JAVASCRIPT for building mobile web applications(For both ipho...