Cody

# Problem 565. Transposition as a CIPHER

Solution 1250009

Submitted on 11 Aug 2017 by Andrew Dobrovolc
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
s1 = 'My name is Sourav Mondal'; y_correct = 'MUYRNAAVMMEOINSDSAOL'; assert(isequal(transposition(s1),y_correct))

y = 'MynameisSouravMondal' y = 'MuyameisSouravMondal' y = 'MuyrneisSouravMondal' y = 'MuyrnaasSouravMondal' y = 'MuyrnaavmouravMondal' y = 'MuyrnaavmMeravMondal' y = 'MuyrnaavmMeoivMondal' y = 'MuyrnaavmMeoinsondal' y = 'MuyrnaavmMeoinsdSdal' y = 'MuyrnaavmMeoinsdSaol'

2   Pass
s1 = 'i am a common cipher'; y_correct = 'IOANMCAICPOHMEMR'; assert(isequal(transposition(s1),y_correct))

y = 'iamacommoncipher' y = 'ioaacommoncipher' y = 'ioanmommoncipher' y = 'ioanmcamoncipher' y = 'ioanmcaicncipher' y = 'ioanmcaicpoipher' y = 'ioanmcaicpohmher' y = 'ioanmcaicpohmemr'

3   Pass
s1 = 'BATMAN rules GOTHAM'; y_correct = 'BEASTGMOATNHRAUML'; assert(isequal(transposition(s1),y_correct))

y = 'BATMANrulesGOTHAM' y = 'BeAMANrulesGOTHAM' y = 'BeAsTNrulesGOTHAM' y = 'BeAsTGMulesGOTHAM' y = 'BeAsTGMOAesGOTHAM' y = 'BeAsTGMOATNGOTHAM' y = 'BeAsTGMOATNHrTHAM' y = 'BeAsTGMOATNHrAuAM' y = 'BeAsTGMOATNHrAuMl'