Cody

# Problem 1080. Guess Cipher

Solution 2014323

Submitted on 11 Nov 2019 at 18:03 by Camilo De La Cruz
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   Pass
x = 'Hello World!'; y_correct = 'Ifmmp Xpsme!'; assert(isequal(si(x),y_correct))

Refvector = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ' PositionM = 35 6 13 13 16 0 50 16 19 13 5 0 1 2 3 4 5 6 7 8 9 10 11 12 lim = 12 y = 'Ifmmp Xpsme!'

2   Pass
x = 'Can I help you?'; y_correct = 'Dbo J ifmq zpv?'; assert(isequal(si(x),y_correct))

Refvector = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ' PositionM = 30 2 15 0 36 0 9 6 13 17 0 26 16 22 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 lim = 15 y = 'Dbo J ifmq zpv?'

3   Pass
x = 'Mary had a liitle lamb.'; y_correct = 'Nbsz ibe b mjjumf mbnc.'; assert(isequal(si(x),y_correct))

Refvector = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ' PositionM = 40 2 19 26 0 9 2 5 0 2 0 13 10 10 21 13 6 0 13 2 14 3 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 lim = 23 y = 'Nbsz ibe b mjjumf mbnc.'