cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
need urgent help
need urgent help
Oct 21, 2012 at 1:38am UTC
closed account (
2wpSLyTq
)
jkygbylbihuhnnb;i
Last edited on
Oct 29, 2012 at 7:23pm UTC
Oct 21, 2012 at 1:47am UTC
closed account (
2wpSLyTq
)
It's a card shuffling program can someone help please?
Last edited on
Oct 21, 2012 at 1:48am UTC
Oct 21, 2012 at 2:15am UTC
rmxhaha
(247)
easy just sort the array based on random
something like
1
2
3
4
5
bool
f(){
return
rand() % 100 < 50; } sort( array.begin(), array.end(), f );
I haven't test my own code. It defenitely won't compile.
This is just one of the way to shuffle an array.
Topic archived. No new replies allowed.