Software Metrics: A Rigorous and Practical Approach, Revised