Hey guys. i'm in an intro to comp sci class and i cant happen to get this program set up properly. my assignment is the first one from www.cs1a.com. I'm using dev C++ and this is what i have so far:
#include<iostream>
#include<stdlib.h>
using namespace std;
// This program was created by Mike Tran.
// This program simulates the game of Blackjack.
int main(void)
{
// Variable List
float playerCard1;
float dealerCard;
float playerCard2;
cout << "Enter a number between 1 and 13: ";
cin >> playerCard1;
cout << "Enter another number between 1 and 13: ";
cin >> playerCard2;
cout << "Enter one more number between 1 and 13: ";
cin >> playerCard3;
if (playerCard==1)
{
system ("pause");
}
it's not much yet, but i'm not sure how to set up the if statements in this case. we've done them before, but none this complicated to our standards. if you guys can help me, that'd be great.
#include<iostream>
#include<stdlib.h>
using namespace std;
// This program was created by Mike Tran.
// This program simulates the game of Blackjack.
int main(void)
{
// Variable List
float playerCard1;
float dealerCard;
float playerCard2;
cout << "Enter a number between 1 and 13: ";
cin >> playerCard1;
cout << "Enter another number between 1 and 13: ";
cin >> playerCard2;
cout << "Enter one more number between 1 and 13: ";
cin >> playerCard3;
if (playerCard==1)
{
system ("pause");
}
it's not much yet, but i'm not sure how to set up the if statements in this case. we've done them before, but none this complicated to our standards. if you guys can help me, that'd be great.