Sololearn: Learn to Code
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1
As this stands, it does not belong here so I marked it for automatic deletion in 24 hours.
21st Feb 2020, 5:08 AM
John Wells
John Wells - avatar
0
Do you mean 2 dimensional array or what?
19th Feb 2020, 8:21 PM
Hanna
Hanna - avatar
0
If you mean a 2d array in C++ this is very simple and explained in C++ tutorial in sololearn. https://www.sololearn.com/Play/CPlusPlus The input is already explained in the following links: https://www.sololearn.com/Discuss/164248/c-arrays-and-cin/ https://www.sololearn.com/Discuss/248504/how-to-input-arrays The following link , in a comment, contains your answer. https://www.sololearn.com/Discuss/688086/how-to-input-a-matrix-using-arrays Your answer in the comment is: int matrix[n_columns][n_lines]; for (size_t i = 0; i < n_columns; ++i) { for (size_t j = 0; j < n_lines; ++j) {cin >> matrix[i][j];} } But please, for your next question use search bar. It's very easy to find already answered questions. Thanks and happy coding!
19th Feb 2020, 8:30 PM
Black Winter