Yes. it can be used like this:
#include <stdio.h>
int main() {
int option;
printf("Enter your choice:\n");
printf("1. Name\n");
printf("2. Age\n");
scanf("%d", &option);
switch(option) {
case 1:
printf("My name is Jack Doe.\n");
break;
case 2:
printf("I am 20 years old.\n");
break;
default:
printf("Invalid option.\n");
}
return 0;
}