I need a function that will populate a multidimensional array with a fixed amount of elements. So that only some of the locations contain a distinguishing number for identification.
boujibabe 0 Junior Poster
Recommended Answers
Jump to Postok maybe I didn't explain this right the array has a fixed amount of rows and columns. I am supposed to randomly populate the array with 12 objects
I wanted to identify the objects with a number such as 1. the user is then prompted to guess the location of …
Jump to Postok maybe I didn't explain this right the array has a fixed amount of rows and columns. I am supposed to randomly populate the array with 12 objects
I wanted to identify the objects with a number such as 1. the user is then prompted to guess the location of …
Jump to PostYou know, LamaBot, you don't have to quote every post in their entirety if you aren't going to reference any part of it. And you can edit the quote down to only show the relevant portions you wish to comment on. That would help by not having a 200 line …
Jump to Postoh, and why are we defining elements to 100?
multi-d[rows][columns] = {{0},{0}};/*Initialize all elements to zero*/
This will initialize the first and second row's first element's to the value of 0.
Since it IS necessary you use a two dimensional array, then the following might give …
Jump to PostI got a more than a little errors most of them say something like
error C2143: syntax error : missing ';' before 'type'
I wonder if this is because The function is located in a separate C file
Yeah that is probably the problem. An easier way to confirm this …
All 49 Replies
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
Lazaro Claiborn 1 Junior Poster
boujibabe 0 Junior Poster
Lazaro Claiborn 1 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
Lazaro Claiborn 1 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
Lazaro Claiborn 1 Junior Poster
boujibabe 0 Junior Poster
boujibabe 0 Junior Poster
Lazaro Claiborn 1 Junior Poster
Lerner 582 Nearly a Posting Maven
boujibabe 0 Junior Poster
Lazaro Claiborn 1 Junior Poster
Lazaro Claiborn 1 Junior Poster
boujibabe 0 Junior Poster
Lazaro Claiborn 1 Junior Poster
Lazaro Claiborn 1 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
boujibabe 0 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
boujibabe 0 Junior Poster
Lazaro Claiborn 1 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
Lazaro Claiborn 1 Junior Poster
WaltP 2,905 Posting Sage w/ dash of thyme Team Colleague
boujibabe 0 Junior Poster
jnabeel 0 Newbie Poster
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.