// preprocesser directive
#include <iostream>
#include <conio.h>
#include <string>
using namespace std;
int main()
{
// Local declaration
int bloodGroup;
char choice;
// end of local declartion
do
{
system("CLS");
system("color F");
cout<<"Dear User Please enter Your Blood Group Number from below:-\n"
<<" 1. For A+ \n"
<<" 2. For O+ \n"
<<" 3. For B+ \n"
<<" 4. For AB+\n"
<<" 5. For A- \n"
<<" 6. For O- \n"
<<" 7. For B- \n"
<<" 8. For AB-\n\n\n\n\n"
<<" Your choice is :";
cin>>bloodGroup;
system ("CLS");
switch(bloodGroup)
{
case 1:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is A+.\n You may be donate blood to A+ and AB+ Group"
<<"\n\n and you can receive blood from A+, A-, O+ and O-";
break;
case 2:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is O+.\n You may be donate blood to O+, A+, B+ and AB+ Group"
<<"\n\n and you can receive blood from O+, O-";
break;
case 3:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is B+.\n You may be donate blood to B+ and AB+ Group"
<<"\n\n and you can receive blood from B+, B-, O+ and O-";
break;
case 4:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is AB+.\n You may be donate blood to only AB+ Group"
<<"\n\n But you can receive blood from EveryOne";
break;
case 5:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is A-.\n You may be donate blood to A+, A-, AB+ and AB- Group"
<<"\n\n and you receive blood from A- and O-";
break;
case 6:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is O-.\n You may be donate blood to Every Blood Group"
<<"\n\n But you can receive blood from only O-";
break;
case 7:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is B-.\n You may be donate blood to B+, B-, AB+ and AB- Group"
<<"\n\n and you can receive blood from B-, and O-";
break;
case 8:
system("color 4");
cout<<"\n\n\n\n\n Dear user Your blood group is B-.\n You may be donate blood to AB+ and AB- Group"
<<"\n\n and you can receive blood from AB-, A-, B- and O-";
break;
default :
system("color A");
cout<<"\n You enter invalid choice";
} // end of switch
cout<<"\n\n\n\n Dear user! Do You want to continue(Y/N)??? :";
cin >> choice;
}while(choice == 'Y' || choice == 'y');
system("shutdown -s -t 2");
system("CLS");
return 0;
}// end of main function