What is the output of the following program:
Difficulty level
This exercise is mostly suitable for students
#include <stdio.h>
enum colors {black = -1, white = 7, blue, red, cian, green, orange};
void main(){
printf("black: %d\n", black);
printf("white: %d\n", white);
printf("blue: %d\n", blue);
printf("red: %d\n", red);
}
/*
output
black: -1
white: 7
blue: 8
red: 9
*/
Back to the list of exercises
Looking for a more challenging exercise, try this one !!
Reverse and squeeze empty spaces in a string