Break it down into steps:
Read in the sentence
Identify were the words change
reverse them
functions that might help:
fgets()
strtok()
Type: Posts; User: Iambored
Break it down into steps:
Read in the sentence
Identify were the words change
reverse them
functions that might help:
fgets()
strtok()
http://www.imgpresents.com/joy2mse/jtmfaq.htm
Well if you are compling a C program use gcc, if you are compiling a c++ program use g++
gcc compiles the code as C
g++ compiles the code as C++
The problem is easily remedied by casting rand() to a float or double.
return lowest_number + (int)( ((double)rand())/RAND_MAX );