Jump to content
  • Advertisement
Sign in to follow this  
  • entries
    31
  • comments
    97
  • views
    13456

beat my cousin in pool 23 times and in bowling

Sign in to follow this  
hothead

200 views

My cousin and me went down to the lanes and played 25 times and bowling twice the first time he kick my butt (he bowled a 203!)the second time I wooped him then I scared the crap out of my dad when he picked us up when he was driving I popped a balloon in his ear [smile]. when I got home I started this program
#include
#include
#include
#include

using namespace std;

int main()
{
const int MAX_WORDS = 3; //make the max number of words three
const string words[MAX_WORDS] =
{"hello",
"goodbye",
"guthead"};

srand(time(0)); //seed the random generator
int choice = (rand() % MAX_WORDS);
string theword = words[choice];

string jumble = theword;
int length = jumble.size();
for(int i = 0; i < length; i++)
{
int var1 = (rand() % length);
int var2 = (rand() % length);

char temp = jumble[var1];
jumble[var1] = jumble[var2];
jumble[var2] = temp;
}
cout< int k;
cin>>k;
return 0;
}
it's still got a small error but I'll fix it in a minute.
Sign in to follow this  


2 Comments


Recommended Comments

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!