Resource icon

CS201 Assignment 2 Solution File Fall 2022-2023

kashif

Administrator
Staff member
VIP Member
Email Verified
kashif submitted a new resource:

CS201 Assignment 2 Solution File - VU CS201 Assignment 2 Solution File Download

This solution idea is for CS201. You should read the whole document carefully and tally the method from your textbook/handout to get maximum numbers.

Rules for Assignments & GDBs:
It should be clear that your Assignments & GDBs will get no marks if:
  • It was submitted after the due date.
  • The submitted file does not open or the file is corrupt. (only for assignments)
  • Submitted solution is copied from another student or the internet.

Recommended:
-...

Read more about this resource...
 
main.cpp:75:1: error: expected ‘}’ at end of input
75 | }
| ^
main.cpp:11:22: note: to match this ‘{’
11 | class MatrixProperty {
| ^
main.cpp: In constructor ‘MatrixProperty::MatrixProperty()’:
main.cpp:16:14: warning: range-based ‘for’ loops with initializer only available with ‘-std=c++2a’ or ‘-std=gnu++2a’
16 | for (int i=0;i<2:1++){ for (int j=0;j<2: j++) { matrix[1][j] = 0;
| ^
main.cpp:16:17: error: expected ‘;’ before ‘:’ token
16 | for (int i=0;i<2:1++){ for (int j=0;j<2: j++) { matrix[1][j] = 0;
| ^
| ;
main.cpp:19:15: error: expected primary-expression before ‘(’ token
19 | MatrixProperty(int a[2][2]) {
| ^
main.cpp:19:16: error: expected primary-expression before ‘int’
19 | MatrixProperty(int a[2][2]) {
| ^~~
main.cpp:19:28: error: expected ‘;’ before ‘{’ token
19 | MatrixProperty(int a[2][2]) {
| ^~
| ;
main.cpp:19:29: error: expected primary-expression before ‘{’ token
19 | MatrixProperty(int a[2][2]) {
| ^
main.cpp:19:28: error: expected ‘)’ before ‘{’ token
19 | MatrixProperty(int a[2][2]) {
| ^~
| )
main.cpp:16:5: note: to match this ‘(’
16 | for (int i=0;i<2:1++){ for (int j=0;j<2: j++) { matrix[1][j] = 0;
| ^
main.cpp:20:11: error: ‘arr’ was not declared in this scope
20 | setMatrix(arr):
| ^~~
main.cpp:20:1: error: ‘setMatrix’ was not declared in this scope
20 | setMatrix(arr):
| ^~~~~~~~~
main.cpp:75:1: error: expected ‘}’ at end of input
75 | }
| ^
main.cpp:19:29: note: to match this ‘{’
19 | MatrixProperty(int a[2][2]) {
| ^
main.cpp:75:1: error: expected ‘}’ at end of input
75 | }
| ^
main.cpp:15:17: note: to match this ‘{’
15 | MatrixProperty(){
| ^
main.cpp: At global scope:
main.cpp:75:1: error: expected unqualified-id at end of input
75 | }
| ^
 
New solution file have been created. Will upload as soon as electricity comes back.
 
Top