A little Rusty (Need help with random)
Hey All,
I haven't touched C in about 6 months. So considering I was never that good to begin with i'm having troubles. :-P Now i'm trying to do something for fun to get back into the swing of things. I'm making 2 arrays with nouns and insults. Each array has 10 nouns and 10 insults. I then want to generate two random numbers between 1 and 10 and then have it print off the number generate from the noun array and the insult array. Follow? Well I did it once. But for the life of me, I can't remember how I did it. This is what I have right now. It's not much to work with, but i was hoping you all could help refresh my memory.
#include <stdio.h>
char insult[7]{
"******";
"*";
"**";
"*";
"*****";
"***";
"****";
},
I'm not even sure if the array is setup right. And yes theres only 7 insults for now. But I can change that to 10 on my own without problem. Any help would be very appretiated.