Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
m = [3 1 5 0 0
3 4 1 5 0
4 2 1 5 0];
srows = [3 1 5 0 0;4 2 1 5 0];
assert(isequal(findsimilar(m),srows))
f1 =
1 1
f2 =
2 1
f1 =
1
f2 =
1
rows =
3 1 5 0 0
4 2 1 5 0
|
2 | Pass |
m = [3 1 5 0 0
1 2 5 0 0
1 3 4 1 5
2 1 5 0 0];
srows = [3 1 5 0 0; 2 1 5 0 0];
assert(isequal(findsimilar(m),srows))
f1 =
1
f2 =
2
f1 =
1 1
f2 =
1 2 1
f1 =
1
f2 =
1
rows =
3 1 5 0 0
2 1 5 0 0
|
3 | Pass |
m = [3 1 5 7 0
3 2 5 7 0
3 5 7 2 0
1 5 7 2 0
4 6 7 8 9
4 5 7 8 0
4 5 6 7 8];
srows = [3 1 5 7 0;1 5 7 2 0;4 6 7 8 9;4 5 7 8 0];
assert(isequal(findsimilar(m),srows))
f1 =
2 1
f2 =
2 1
f1 =
2 1
f2 =
1 1
f1 =
1 1
f2 =
1 1
f1 =
[]
f2 =
[]
f1 =
1
f2 =
1
f1 =
1
f2 =
2
rows =
3 1 5 7 0
1 5 7 2 0
4 6 7 8 9
4 5 7 8 0
|
4 | Pass |
m = [3 1 5 0 0
3 1 6 0 0
3 2 6 0 0
2 1 5 6 0];
srows = m;
assert(isequal(findsimilar(m), srows))
f1 =
1
f2 =
1
f1 =
[]
f2 =
[]
f1 =
1
f2 =
1
rows =
3 1 5 0 0
3 1 6 0 0
3 2 6 0 0
2 1 5 6 0
|
831 Solvers
289 Solvers
329 Solvers
323 Solvers
215 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!