//C++ program that will take input an integer for the month and displays users season (Indian season) name according to the input
#include<iostream.h>
#include<conio.h>
main()
{
clrscr();
int m;
cout <<"enter any months";
cin >> m;
if (m==12 || m==1 || m==2)
{
cout << "It is a winter season" <<endl;
}
if (m==3 || m==4 || m==5 || m==6)
{
cout << "It is a summer season";
}
if (m==7 || m==8 || m==9)
{
cout <<"It is a rainy season";
}
if (m==10 || m==11)
{
cout << "It is an autumn";
}
getch();
}
Jun 5, 2007
C++ program
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment