I need to write a program, that if anyone ever played memory when they were younger does exactly that, that asks a user for 8 numbers. the numbers the user inputs need to be scattered across a 4x4 array. for example if a user enters 4 there need to be two of them in different sections of the array. so there will be a total of 16 "cards" or numbers. then the user will enter a array block to check two to check if they are equal - just like the game memory. im having problems knowing how to separate the list of numbers that the user inputs to enter each number into a different array. CAN ANYONE HELP PLEASE!!
angleyz14
0
Newbie Poster
Recommended Answers
Jump to PostYou need to know about
- 2-dimensional arrays
- random number generating
- user inputWhat do you have so far?
Jump to PostYou need to know about
- 2-dimensional arrays
- random number generating
- user inputWhat do you have so far?
Yes
The two dimensional array can be a pointer pointing to a one dimensional array. So that it will be very easy to allocate.And use a forever …
All 7 Replies
Nick Evan
4,005
Industrious Poster
Team Colleague
Featured Poster
Sky Diploma
571
Practically a Posting Shark
Arne Kristoffer
0
Light Poster
angleyz14
0
Newbie Poster
Arne Kristoffer
0
Light Poster
angleyz14
0
Newbie Poster
vmanes
1,165
Posting Virtuoso
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.