Skip to content

Commit c5605d7

Browse files
authored
Sync docs for practice exercise atbash-cipher (exercism#2376)
1 parent 2488365 commit c5605d7

1 file changed

Lines changed: 8 additions & 10 deletions

File tree

exercises/practice/atbash-cipher/.docs/instructions.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,8 @@
22

33
Create an implementation of the atbash cipher, an ancient encryption system created in the Middle East.
44

5-
The Atbash cipher is a simple substitution cipher that relies on
6-
transposing all the letters in the alphabet such that the resulting
7-
alphabet is backwards. The first letter is replaced with the last
8-
letter, the second with the second-last, and so on.
5+
The Atbash cipher is a simple substitution cipher that relies on transposing all the letters in the alphabet such that the resulting alphabet is backwards.
6+
The first letter is replaced with the last letter, the second with the second-last, and so on.
97

108
An Atbash cipher for the Latin alphabet would be as follows:
119

@@ -14,16 +12,16 @@ Plain: abcdefghijklmnopqrstuvwxyz
1412
Cipher: zyxwvutsrqponmlkjihgfedcba
1513
```
1614

17-
It is a very weak cipher because it only has one possible key, and it is
18-
a simple monoalphabetic substitution cipher. However, this may not have
19-
been an issue in the cipher's time.
15+
It is a very weak cipher because it only has one possible key, and it is a simple mono-alphabetic substitution cipher.
16+
However, this may not have been an issue in the cipher's time.
2017

21-
Ciphertext is written out in groups of fixed length, the traditional group size
22-
being 5 letters, and punctuation is excluded. This is to make it harder to guess
23-
things based on word boundaries.
18+
Ciphertext is written out in groups of fixed length, the traditional group size being 5 letters, leaving numbers unchanged, and punctuation is excluded.
19+
This is to make it harder to guess things based on word boundaries.
20+
All text will be encoded as lowercase letters.
2421

2522
## Examples
2623

2724
- Encoding `test` gives `gvhg`
25+
- Encoding `x123 yes` gives `c123b vh`
2826
- Decoding `gvhg` gives `test`
2927
- Decoding `gsvjf rxpyi ldmul cqfnk hlevi gsvoz abwlt` gives `thequickbrownfoxjumpsoverthelazydog`

0 commit comments

Comments
 (0)