//Variable declaration: C = 1 //Number of constituents P = 1 //Number of phases //Calculation: F = C-P+2 //Number of degrees of freedom //Result: printf("The number of degrees of freedom is : %.2f .",F)