Like magic(4) = 16 3 2 13;5 10 11 8;9 6 7 12;4 15 14 1
Please correct the test suite so there are brackets around your y_correct. Adding a couple of other magic squares (5 and 6) would also help.
Hi Anumpam: Thanks for the problem. You need to fix the test suite as James says. Also, since you haven't specified what order you want the numbers in, you should probably check to make sure the matrix has magic properties (rows add to the same number, etc.) rather than testing that it matches exactly one matrix. There are lots of magic 4-by-4 matrices.
Hi Anupam, could you please correct this testsuite? (just change the line that reads "y_correct = 16 3 2 13;5 10 11 8;9 6 7 12;4 15 14 1" to read instead "y_correct = [16 3 2 13;5 10 11 8;9 6 7 12;4 15 14 1]")
I have changed as Mr. Alfonso says... but still problem exists...
The testsuite does not appear to be changed at all. Click on 'Edit' to edit this problem, then go to textbox titled 'Test Suite', add the brackets there to the "y_correct = ..." line, then click on the 'Save' button. Ideally you would also try out your own solution to this problem (in the textbox titled 'Reference Solution') and click on the 'Test reference solution' button to make sure that everything is working as expected...
yeah... now the prob is solved... thanks to all ... specially to mr. alfonso
Select every other element of a vector
16247 Solvers
14354 Solvers
740 Solvers
172 Solvers
364 Solvers