// An example declaring and printing variables // of types int, double and char // for COMP1511/1911 24T3 // Written by: z9801583 // Date: 12/09/2024 #include int main(void) { // Declare and initialise an int variable int num_students = 1100; // Declare and initialise a double double lab_mark = 2.2; // Print the int and the double variable printf("Num students: %d lab_mark: %lf\n", num_students, lab_mark); // Declare and initialise a char variable char grade = 'A'; // Print the char variable printf("Wow! You got an %c\n", grade); // Modify the double variable lab_mark = 2.587652938172626; // Print the double variable to 2 decimal places printf("Lab Mark %.20lf\n",lab_mark); return 0; }