Codeforces Beta Round 52 (Div. 2)
A
Bar
Codeforces
1000
原题
←B →
翻译中…

According to Berland laws it is only allowed to sell alcohol to people not younger than 18 years. Vasya's job is to monitor the law's enforcement. Tonight he entered a bar and saw $*n*$ people sitting there. For every one of them Vasya happened to determine either the age or the drink the person is having. Vasya can check any person, i.e. learn his age and the drink he is having at the same time. What minimal number of people should Vasya check additionally to make sure that there are no clients under 18 having alcohol drinks?

翻译中…

The list of all alcohol drinks in Berland is: ABSINTH, BEER, BRANDY, CHAMPAGNE, GIN, RUM, SAKE, TEQUILA, VODKA, WHISKEY, WINE

翻译中…

Input

翻译中…

The first line contains an integer $*n*$ ($1 ≤ *n* ≤ 100$) which is the number of the bar's clients. Then follow $*n*$ lines, each describing one visitor. A line either contains his age (an integer from 0 to 1000) or his drink (a string of capital Latin letters from 1 to 100 in length). It is guaranteed that the input data does not contain spaces and other unnecessary separators.

翻译中…

Only the drinks from the list given above should be considered alcohol.

翻译中…

Output

翻译中…

Print a single number which is the number of people Vasya should check to guarantee the law enforcement.

翻译中…

Note

翻译中…

In the sample test the second and fifth clients should be checked.

翻译中…

样例

Input #1
5
18
VODKA
COKE
19
17
Output #1
2
InputCopy OutputCopy
题目信息
题号
56A
时间限制
2 s
内存限制
256 MB
标签
模拟

题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。