c printf double 4 decimal code example Example: print double with 2 decimals c printf("%.2f", number);