ГлавнаяСборникиТурнирыРазделыФорумыУчастникиПечатьПомощьО системе

Турниры > CEN303 2013-15 Questions > задача:


15HW-40. 50829 - Decode an Image

CEN303 2013-15 Questions

Старт: 15.дек.2013 в 14:00:00
Финиш: 15.дек.2013 в 19:00:00
Турнир завершён!
• Турнирная таблица

Гость
• Вопросы к жюри (1)

Задачи турнира

• 14-FallResit-10. 50525 - Ordering Pizza
• 14-FallResit-20. 50488 - Connecting...
• 15FE-01. 50851 - Repeated Numbers
• 15FE-01. 50838 - Balanced Numbers
• 15FE-04. 50997 - Dynamic Knights
• 15HW-10. 50826 - Olive Containers
• 15HW-30. 50828 - Arranging Time ...
• 15HW-40. 50676 - Cinema Millennium
• 15HW-40. 50829 - Decode an I...
• 15HW-50. 50830 - Sorting BST Nodes
• 15HW-60. 50678 - The Jumping Rabbit
• 15MdE-10. 50802 - Comparing Exams
• 15MdE-20. 50803 - Sum of the dept...
• 15MdE-40. 50805 - Sum of the weig...
• 15PrE-10. 50816 - Largest Sum Path
• 15PrE-20. 50817 - The Knight Move
• 15PrE-30. 50818 - Depth Limited BST

Обратная связь

Если у вас есть предложения или пожелания по работе Contester, посетите форум сайта www.contester.ru.

Лимит времени 2000/4000/4000/4000 мс. Лимит памяти 65000/65000/65000/65000 Кб.
Question by Ibrahim Mesecan.

Decode an Image

You will be given encoding of an image. And that will be followed by the image itself. Decode and show it.

Input specification
In the first line, you will be given an integer: The number of codes(n) where 0 ≤ n ≤ 2000. Then, in the following n lines, you will be given:

  • The name of pattern: at most 12 chars string
  • The code: At most 25 char string containing only 1 or 0
Then, you will be given an integer (k) the number of lines. In the following k lines you will be given the image where k is not greater than 500 and in every line you have at most 150 ones or zeros.

Output specification:
Show decoded image.

Sample Input I
4
as 1
bd 01
c 001
d 000
3
10010
10101
01000
Sample Output I
as c bd bd bd bd d



Для отправки решений необходимо выполнить вход.

www.contester.ru