Problems

Age
Difficulty
Found: 1506

Find one way to encrypt letters of Latin alphabet as sequences of \(0\)s and \(1\)s, each letter corresponds to a sequence of five symbols.

Using the representation of Latin alphabet as sequences of \(0\)s and \(1\)s five symbols long, encrypt your first and last name.

Decipher the quote from "Alice in Wonderland" from the following matrix:
\[\begin{array}{@{}*{26}{c}@{}} Y&q&o&l&u&e&c&d&a&i&n \\ w&a&r&l&a&w&e&a&t&y&k \\ s&n&t&c&a&e&k&c&e&a&m \\ t&o&d&r&w&e&a&t&a&h&r \\ a&c&n&t&n&e&o&d&t&r&h \\ n&i&d&n&l&g&m&e&x&s&z \end{array}\]

Decipher the following quote from Alice in Wonderland:
Lw zrxog eh vr qlfh li vrphwklqj pdgh vhqvh iru d fkdqjh.
The same letters correspond to the same in the phrase, different letters correspond to different. We know that no original letters stayed in place, meaning that in places of e,r,h there was surely something else.

After mastering the Caesar shift cypher one may wonder how to generalize it. One possible way is to use Affine cypher. The difference between these two methods can be described as follows:

  • In case of Caesar cypher we took a letter with position \(n\) from \(1\) to \(26\) and added to its position a number \(d\) obtaining the number \(n+d\), then we compute its residue modulo \(26\).

  • In case of affine cypher we take a letter with position \(n\) and consider a number \(nx + d\) modulo \(26\).

To decipher such code we need to know values \(x\) and \(d\), then if we have a letter in the code with position \(m\), we can find \(n\) as \(n= (m-d)x^{-1}\) modulo \(26\). Here we have to explain what is \(x^{-1}\): for a number \(x < 26\) we are looking for such a number \(y\), that \(26\) divides \(xy-1\).

  • Does there always exist a number \(x^{-1}\) modulo \(26\) for any \(x\)?

  • Using data \(x=3\), \(d=8\) encrypt the word "SOLUTION".

Bryn calls the date beautiful if all \(6\) digits of the date entry are different. For example: 19.04.23 is a beautiful date, but 19.02.23 and 01.06.23 are not. How many beautiful dates are there in \(2023\)?

On the grid paper, Theresa drew a rectangle \(199 \times 991\) with all sides on the grid lines and vertices on intersection of grid lines. How many cells of the grid paper are crossed by a diagonal of this rectangle?

The school cafeteria offers three varieties of pancakes and five different toppings. How many different pancakes with toppings can Emmanuel order? He has to have exactly one topping on each pancake.

How many six-digit numbers are there, all of whose digits are the same parity? That is, all digits are even, or all digits are odd.

Donald’s sister Maggie goes to a nursery. One day the teacher at the nursery asked Maggie and the other children to stand a circle. When Maggie came home she told Donald that it was very funny that in the circle every child held hands with either two girls or two boys. How many girls were standing in the circle, if there were five boys?