ifedyukin / hacktoberfest-js-utils

Enjoy! #hacktoberfest
2 stars 11 forks source link

Implement "Atbash" function and write new test #27

Closed ifedyukin closed 6 years ago

bakoushin commented 6 years ago

Task description

Implement Atbash cipher/deciper for Latin alphabet. Atbash is an old Hebrew substitution cipher, used in Bible. Wikipedia

In the Atbash cipher, alphabet is mapped to its reverse, so the first letter becomes the last letter, the second letter becomes the second to last letter, and so on.

Atbash mapping for Latin alphabet:

A|B|C|D|E|F|G|H|I|J|K|L|M
Z|Y|X|W|V|U|T|S|R|Q|P|O|N