The railfence cipher scrambles the letters of a message. Below is an example of how to cipher a message using railfence
This is how one would encode the word "railfence":
- Draw up a grid as shown above
- Write your message in as a zig-zag like above. Ignore spaces
- If there is an odd number of characters, add a place filler letter in the last cell (shown in red)
- Copy down all the letters from the first row, then the second row
and now "railfence" becomes "rifnealeca".