Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
%%
inString1 = 'I am ready to try it - with punctuation and CAPS!';
outString1a = 'F xj obxav ql qov fq - tfqe mrkzqrxqflk xka ZXMP!';
assert(isequal(simpleDecoderRing(inString1,-3),outString1a ));
ans =
1 3
ans =
............................... !"#$%&'()*+,-./0123456789:;<=>?@XYZABCDEFGHIJKLMNOPQRSTUVW[\]^_`xyzabcdefghijklmnopqrstuvw
ans =
F xj obxav ql qov fq - tfqe mrkzqrxqflk xka ZXMP!
|
2 | Pass |
%%
inString1 = 'I am ready to try it - with punctuation and CAPS!';
outString1b = 'L dp uhdgb wr wub lw - zlwk sxqfwxdwlrq dqg FDSV!';
assert(isequal(simpleDecoderRing(inString1,3),outString1b ));
ans =
1 -3
ans =
............................... !"#$%&'()*+,-./0123456789:;<=>?@DEFGHIJKLMNOPQRSTUVWXYZABC[\]^_`defghijklmnopqrstuvwxyzabc
ans =
L dp uhdgb wr wub lw - zlwk sxqfwxdwlrq dqg FDSV!
|
3 | Pass |
%%
inString2 = 'Dick Tracy is often associated with decoder rings.';
outString2a = 'Lqks Bzikg qa wnbmv iaawkqibml eqbp lmkwlmz zqvoa.';
assert(isequal(simpleDecoderRing(inString2,-18),outString2a ));
ans =
1 18
ans =
............................... !"#$%&'()*+,-./0123456789:;<=>?@IJKLMNOPQRSTUVWXYZABCDEFGH[\]^_`ijklmnopqrstuvwxyzabcdefgh
ans =
Lqks Bzikg qa wnbmv iaawkqibml eqbp lmkwlmz zqvoa.
|
4 | Pass |
%%
inString2 = 'Dick Tracy is often associated with decoder rings.';
outString2b = 'Zeyg Pnwyu eo kbpaj wookyewpaz sepd zaykzan nejco.';
assert(isequal(simpleDecoderRing(inString2,22),outString2b ));
ans =
1 -22
ans =
............................... !"#$%&'()*+,-./0123456789:;<=>?@WXYZABCDEFGHIJKLMNOPQRSTUV[\]^_`wxyzabcdefghijklmnopqrstuv
ans =
Zeyg Pnwyu eo kbpaj wookyewpaz sepd zaykzan nejco.
|
657 Solvers
Find state names that start with the letter N
598 Solvers
Change the sign of even index entries of the reversed vector
296 Solvers
The Answer to Life, the Universe, and Everything
383 Solvers
Create an n-by-n null matrix and fill with ones certain positions
268 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!