Logo

Programming-Idioms

History of Idiom 26 > diff from v75 to v76

Edit summary for version 76 by Narc:
[C++] Removed 'Explain stuff'

Version 75

2020-09-07, 14:29:02

Version 76

2020-09-07, 14:29:26

Idiom #26 Create a 2-dimensional array

Declare and initialize a matrix x having m rows and n columns, containing real numbers.

Idiom #26 Create a 2-dimensional array

Declare and initialize a matrix x having m rows and n columns, containing real numbers.

Variables
x,m,n
Variables
x,m,n
Imports
#include <vector>
Imports
#include <vector>
Code
std::vector<std::vector<double>> x (m, std::vector<double>(n));
Code
std::vector<std::vector<double>> x (m, std::vector<double>(n));
Comments bubble
Formatting.