double having only 2 decimal places in c\ code example
Example 1: c# double value with 2 decimal places
inputValue = Math.Round(inputValue, 2);
Example 2: print double with 2 decimals c
printf("%.2f", number);
inputValue = Math.Round(inputValue, 2);
printf("%.2f", number);