Questions tagged [cipher]
For challenges relating in some way to encoding messages using classical (pen and paper) ciphers. For modern ciphers, such as AES, use the [encryption] tag instead.
32
questions
8
votes
10
answers
2k
views
Decrypt an Autokey Cipher
The autokey cipher is closely related to the Vigenère cipher (both were invented by Blaise de Vigenère). Decryption involves the encrypted message and the key. For simplicity, let us assume all ...
17
votes
18
answers
1k
views
Play Caesar's Cipher with Letters only
Description
The Caesar cipher is a cipher, where every letter in the alphabet will be rotated by a secret number.
If the rotation is \$7\$, then a -> ...
14
votes
8
answers
692
views
Crack the Caesar cipher
The Caesar cipher is a simple and famous cipher, where the letters of the alphabet are rotated by some secret amount. For example, if our secret rotation is 3, we ...
19
votes
13
answers
663
views
Self-unshuffling strings
To shuffle a string \$s\$, Alice applies the following algorithm:
She takes the ASCII code of each character, e.g. "GOLF" → \$[ 71, 79, 76, 70 ]\$
She ...
19
votes
21
answers
2k
views
Alienese cycles
Alienese refers to two "languages" in the show Futurama. In actuality, they are two ciphers of English text with a pictographic alphabet. The first is a simple substitution cipher, but the ...
3
votes
5
answers
337
views
Write A Book Cipher [closed]
Introduction
Book cipher
A Book cipher is a very unique method of a encipher. Here's how's it done:
You have a book / a document or a article (something full of text, the more pages of text the ...
10
votes
8
answers
627
views
Implement bottom (encode)
Challenge
The challenge is to implement the bottom encoding (only encoding, not decoding). There is a wide variety of existing implementations in the bottom-software-foundation org.
Bottom is a text ...
7
votes
2
answers
258
views
Unscramble the letters by letter frequency analysis [closed]
You know those riddles where every letter is swapped for another letter?
E.g. you get a text like
...
17
votes
19
answers
2k
views
Clock (transliterate) Cipher
Introduction:
I have loads of different ciphers stored in a document I once compiled as a kid, I picked a few of the ones I thought were best suitable for challenges (not too trivial, and not too ...
19
votes
13
answers
2k
views
Trifid Cipher (without keyword)
Introduction:
I have loads of different ciphers stored in a document I once compiled as a kid, I picked a few of the ones I thought were best suitable for challenges (not too trivial, and not too hard)...
16
votes
14
answers
2k
views
Computer Cipher
Introduction:
I have loads of different ciphers stored in a document I once compiled as a kid, I picked a few of the ones I thought were best suitable for challenges (not too trivial, and not too hard)...
33
votes
20
answers
3k
views
The Improved Caesar Pig Latin Cipher
The problem with the Caesar cipher is the resulting words are often unpronounceable. The problem with Pig Latin is that it is easy to decode. Why not combine them?
Input
A word consisting of the ...
15
votes
14
answers
2k
views
A Capital Cipher
Your task is to decipher a non-empty string consisting of printable ASCII characters in the range [32..126].
Reading the string character per character:
each time you encounter a letter in lowercase, ...
21
votes
15
answers
9k
views
The Keyboard Shift Cipher
Given the following input:
An integer n where n > 0.
A string s where ...
0
votes
5
answers
279
views
Encrypt a string using vigenere techniques [duplicate]
Your task:
Create a program that encrypts a string with another string using a key, using
the vigenere cipher.
What a vigenere cipher does
...
38
votes
14
answers
5k
views
579085261 is CRAZY, 725582 is GOLF, 10757494 is ...?
Your task is to translate a 103-smooth number into an English word, using the method described below.
How?
Generate the list of prime factors (with repetition) of the input number.
Sort the list:
...
19
votes
9
answers
1k
views
Garbled Phone Numbers
You know how you get a voicemail message and the person's connection wasn't great, and you're trying to figure out how to call them back, but you're not sure if that was a "5" or an "8" they said?
...
18
votes
16
answers
2k
views
Incremental Cipher
This task is rather simple, and makes use of three distinct "operator" characters. Your task is, given a simple sequence of letters, perform the following task to encode it using ...
37
votes
17
answers
2k
views
Let's do some “enciph5r47g”
This is the inverse of Let's do some "deciph4r4ng"
In this challenge, your task is to encipher a string. Luckily, the algorithm is pretty simple: reading from left to right, each ...
62
votes
37
answers
4k
views
Let's do some "deciph4r4ng"
In this challenge, your task is to decipher a string. Luckily, the algorithm is pretty simple: reading from left to right, each encountered digit N (0 to 9) must be replaced with the character which ...
4
votes
4
answers
459
views
Encode the backwards alphabet cipher
Given a string of text that contains lowercase letters, encode it as follows: (I will be using abcdef)
First, encode the alphabet cipher, but this time, 0-indexed. ...
2
votes
0
answers
151
views
Encode the simple substitution cipher [duplicate]
Review
First, let's review the Simple Substitution Cipher.
To encode a string in the Simple Substitution Cipher, replace each letter in your string with another letter.
A letter may not be used to ...
27
votes
16
answers
2k
views
Decode Baby-talk!
When babies open their mouths, they're not just spewing gibberish. They're actually talking in a highly advanced, adult-proof cipher...
The Baby-talk Cipher
When a baby talks, it could look ...
8
votes
25
answers
663
views
Encode the column cipher
Given a string to encode, and a number of columns (the key), encode the string as follows:
I will be using the example Hello, world! and the key ...
28
votes
64
answers
3k
views
Encode the alphabet cipher
Given a string that contains only lowercase letters, encode that string with the alphabet cipher.
To encode with the alphabet cipher (I will be using the example ...
14
votes
10
answers
2k
views
ASCII Odd/Even Cipher
We'll define the ASCII Odd/Even Cipher via the below pseudocode:
...
10
votes
2
answers
335
views
Marcel Proust and Markov decipher security service’s T9 texts
As if this challenge could be any more Pythonesque in spirit... No prior knowledge of Markov chains or encryption techniques is required.
You are a spy who needs to obtain some crucial information ...
7
votes
10
answers
2k
views
Columnar Transposition Cipher
Columnar Transposition Cipher
While I have plenty of programs I have written for more advanced ciphers, I just realised I don't actually have one for one of the simplest: Columnar Transposition. The ...
6
votes
2
answers
604
views
ADFGX Cipher Encryption
ADFGX cipher encryption
The ADFGX cipher was used by the German army in WWI. Write a program to encipher with it!
It works as follows:
Create a 5x5 Polybius square with a mixed alphabet. The ...
22
votes
16
answers
3k
views
Caesar Shifting
A Caesar shift is probably something we're all familiar with.
(You might be even doing it as a homework task. If so, please don't copy these answers, your teacher almost certainly doesn't want ...
11
votes
5
answers
8k
views
Rail fence cipher
Write two programs:
- One which reads a string and a key and encodes the string into a rail-fence cipher using that key.
- Similarly, write a program for the reverse function: deciphering a rail fence ...
30
votes
20
answers
4k
views
Decipher a Vigenère ciphertext
The Vigenère cipher was a simple polyalphabetic cipher that basically applied one of several Caesar ciphers, according to a key. Basically the letters in the key indicate which shifted alphabet to use....