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

Сборники > Задачи со всего света > задача:


190. 50533 - Contacts List

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

Задачи сборника

• 135. 50572 - Numrat Palindrome
• 140. 50393 - Palindromic Numbers
• 145. 50586 - Palindrome te thjeshta
• 148. 50412 - K numbers
• 150. 50375 - Area of Circles
• 160. 50388 - Number of Armstrong ...
• 160. 50571 - Numrat Armstrong
• 165. 50577 - Numrat perfekte dhe ...
• 190. 50533 - Contacts List
• 200. 50454 - What day is it?
• 210. 50369 - Base Conversion
• 250. 50385 - The 3n + 1 problem
• 260. 50493 - n-digit kth Prime Number

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

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

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

Contacts List

You are required to build a very simple application that can search for the contacts stored in the phone by taking a query from the user.

Question: Take the list of the contacts and a query string and decide if each of the contacts contains in it or not.

Input specification
You will be given an integer (1 <= n <= 50000) which represents the number of the contacts. In another line, you will get a short query (a String composed only of 2 characters). In the following n lines, you will get the name of each contact (a String of length at most 10 characters).

Output specification
Show each of the names that contains the query in the same order as in the input. If there is no match, show the message "No matching." without the quotes.

Sample Input I
5
an
Agim
Dorian
Ardit
Arjan
Agon
Sample Output I
Dorian
Arjan



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

www.contester.ru