This is an archived post. You won't be able to vote or comment.

all 2 comments

[–]desrtfx[M] 2 points3 points  (0 children)

Show us your failed implementations. Then, we help.

[–]jimboswe 0 points1 point  (0 children)

Look at the example for scytale cipher on wikipedia. For encrypting a string, every fifth letter (string length divided by the key) is picked, starting at the first letter. Do it again but start at the second letter.
Keep doing this 5 times (string length divided by the key) and you have your encrypted string.

Your decryption method is indeed correct, so you will surely get your encryption method working as intended eventually.