#include <iostream.h>
#include <stdlib.h>
int main()
{
int x;
int y;
int entry;
cout <<"///////////// /Easy Math Calculator ///////////////"<< endl;
cout <<" [email protected]\n\n";
cout <<"Hey! You want to see this program do your own simple math quotation?"<< endl;
cout <<"Enter a number and press Enter.."<< endl;
cin >> x;
cout <<"The number you just entered was, " << x << endl;
cout <<"Please Enter another number and press Enter..."<< endl;
cin >> y;
cout <<"Do you want the Program do devide your numbers, multiply, add or subtract?\n\n";
cout <<" Press M and Enter for multiply\n\n";
cout <<" Press D and Enter for Devide\n\n";
cout <<" Press S and Enter for Subtraction\n\n";
cout <<" Press A and Enter for Addition\n\n";
cin >> entry;
if (entry = "A")
{
cout <<"Your Numbers Have been...ADDED!\n\n";
}
system("PAUSE");
return 0;
}
I need help cause on line if (entry = "A") it sais it lacks a cast...and i have no idea what that means. All i want it to do is to ask the person if the want there numbers added, multiplyed, devided or subtracted..and then the if (entry = "A") thing is for addition so it would write out "Your numbers have been..ADDED!" can anyone help me with why this isnt working?