7 kyu
GA-DE-RY-PO-LU-KI cypher
807 of 2,833dcieslak
Description:
Introduction
The GADERYPOLUKI is a simple substitution cypher used in scouting to encrypt messages. The encryption is based on short, easy to remember key. The key is written as paired letters, which are in the cipher simple replacement.
The most frequently used key is "GA-DE-RY-PO-LU-KI".
G => A
g => a
a => g
A => G
D => E
etc.
The letters, which are not on the list of substitutes, stays in the encrypted text without changes.
Task
Your task is to help scouts to encrypt and decrypt thier messages.
Write the Encode
and Decode
functions.
Input/Output
The input string consists of lowercase and uperrcase characters and white . The substitution has to be case-sensitive.
Example
encode("ABCD") // => GBCE
encode("Ala has a cat") // => Gug hgs g cgt
encode("gaderypoluki"); // => agedyropulik
decode("Gug hgs g cgt") // => Ala has a cat
decode("agedyropulik") // => gaderypoluki
decode("GBCE") // => ABCD
GADERYPOLUKI collection
GADERYPOLUKI cypher vol 1 |
GADERYPOLUKI cypher vol 2 |
GADERYPOLUKI cypher vol 3 - Missing Key |
GADERYPOLUKI cypher vol 4 - Missing key madness |
Fundamentals
Ciphers
Cryptography
Similar Kata:
Stats:
Created | May 28, 2017 |
Published | May 28, 2017 |
Warriors Trained | 5367 |
Total Skips | 160 |
Total Code Submissions | 7658 |
Total Times Completed | 2833 |
JavaScript Completions | 807 |
C# Completions | 257 |
Ruby Completions | 108 |
Crystal Completions | 15 |
Python Completions | 1103 |
TypeScript Completions | 132 |
C++ Completions | 399 |
Go Completions | 94 |
Rust Completions | 60 |
Lua Completions | 9 |
Total Stars | 73 |
% of votes with a positive feedback rating | 90% of 514 |
Total "Very Satisfied" Votes | 427 |
Total "Somewhat Satisfied" Votes | 74 |
Total "Not Satisfied" Votes | 13 |
Total Rank Assessments | 11 |
Average Assessed Rank | 6 kyu |
Highest Assessed Rank | 6 kyu |
Lowest Assessed Rank | 7 kyu |