Cody

Problem 753. Solitaire Cipher

Solution 2940205

Submitted on 12 Sep 2020
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
deck = 1:28; n = 10; out = [3 22 9 4 23 7 25 16 14 14]; assert(isequal(solitaire(deck, n),out))

out = 1 13 8 1 8 18 24 19 18 4

Assertion failed.

2   Fail
deck = 1:28; n = 9; out = [3 22 9 4 23 7 25 16 14]; assert(isequal(solitaire(deck, n),out))

out = 1 13 8 1 8 18 24 19 18

Assertion failed.

Suggested Problems

More from this Author52

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!