07-25-2023, 10:52 AM
`printf()` is used to display output to the console, and scanf() is used to read input from the user.
int age;
printf("Enter your age: ");
scanf("%d", &age);
printf("Your age is %d\n", age);
int age;
printf("Enter your age: ");
scanf("%d", &age);
printf("Your age is %d\n", age);
Also follow me on Youtube for videos about video games:
https://www.youtube.com/channel/UCxfkGVU...2mQ/videos
https://www.youtube.com/channel/UCxfkGVU...2mQ/videos