title: Software product pricing/cost estimation
body: <p>I always had trouble with estimating cost/price of finished software (or programming work), so here are two questions about it.  </p>
  
  <p><strong>question 1</strong>:<br>
  You're asked to write a piece of code for cash (all rights to the code belongs to buyer once you're done). You know approximate number of hours it will take (+-25%), and approximate complexity (i.e. whether you can write it in your sleep or will suffer severe mental burnout once you're done). Product is written in compiled language (C, C++, etc.).</p>
  
  <p>How do you(would you) pick price for the job? </p>
  
  <p><strong>question 2</strong>:<br>
  Let's say you spend a few months writing something, this thing is now finished, and now want to (try to) sell it.</p>
  
  <p>Product will be extremely "Niche", and it won't be possible to sell it for large numbers of people (it is SDK, game engine, library, or something like that, not a text editor - number of people that would want it will be small). "opensourcing" it is out of the question.</p>
  
  <p>You know approximate number of hours you spent, total size of files, LoC, and you have a repository with entire development history.</p>
  
  <p>The result can be sold with or without source code access, for commercial or non-commercial use, or you can (try to) sell software rights.</p>
  
  <p>How do you determine price for:</p>
  
  <ol>
  <li>Rights for that piece of software?  </li>
  <li>Commercial use with source code access?</li>
  <li>Commercial use without source code access?</li>
  <li>Non-commercial use?</li>
  </ol>