// by Robert Oschler
function StressLevelInProgramming : extended;
begin
// the constant 0.001 was added to the Max() function in the denominator
// because once the number of hours left on the project is less than 1,
// the programmer's stress/pain approaches infinity asymptotically.
// And to avoid a divide by zero Exception of course.
result := AbsDistance(intendedFunction, actualFunction) * (1 / Max(NumHoursTillDeadline, 0.001));
end;
Have you noticed how time passes by more quickly as you approach "The Deadline"? The function you are working on seems more complicated than when you created the function header and perfectly knew what the function should return and how to code it?
Finally, the stress calculator you can use to explain to your boss why the Deadline should be tomorrow and not today :)
Can you come up with a more accurate function?
