#include
#include
void main(){
clrscr();
int day,z,d;
gotoxy(30,3);textcolor(LIGHTCYAN);cprintf("E X E R C I S E 4");
gotoxy(28,5);textcolor(LIGHTRED);cprintf("Enter an integer:");
scanf("%d",&day);
switch(day){
case 1:
gotoxy(35,7);textcolor(LIGHTGREEN+BLINK);cprintf("Sunday");
break;
case 2:
gotoxy(35,7);textcolor(LIGHTRED+BLINK);cprintf("Monday");
break;
case 3:
gotoxy(35,7);textcolor(MAGENTA+BLINK);cprintf("Tuesday");
break;
case 4:
gotoxy(35,7);textcolor(GREEN+BLINK);cprintf("Wednesday");
break;
case 5:
gotoxy(35,7);textcolor(CYAN+BLINK);cprintf("Thursday");
break;
case 6:
gotoxy(35,7);textcolor(YELLOW+BLINK);cprintf("Friday");
break;
case 7:
gotoxy(35,7);textcolor(LIGHTBLUE+BLINK);cprintf("Saturday");
break;
default:
gotoxy(20,9);textcolor(CYAN);cprintf("S O R R Y ! ! !Day is not available!!!!!");}
getch();
}
OUTPUT:
No comments:
Post a Comment