When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For more information use !howto ask.
7 messages · Page 1 of 1 (latest)
When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For more information use !howto ask.
try num = rand() % 8 instead. srand is for seeding once. rand is for getting the random numbers. % 8 is for getting the remainder so its a small number.
currently your code doesn't really do anything except prints with cout 99% of the time
or 100% of the time depending what srand returns
so unfortunately in the current state there is not enough info to know what you are doing
!solved