Logo
(追記) (追記ここまで)

33554번 - Grand Opening 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 2048 MB47361680.000%

문제

Working at a lock recycling company can be a pain, especially when the locks need to be unlocked and reusable and people forgot to turn in their keys. A friend that works at such a company has found a solution to this problem: a bump key. Your friend has a list of specifications for the tumblers in each lock, and needs your help. You are tasked with finding out which locks he should attempt to open using a bump key, and which locks are for the furnace.

The key and locks are made of the character "#", and the rest is indicated by a dot. In the example below, you can see that the key on the left doesn't fit the lock on the right. The parts where the key doesn't fit are marked with a "しかく".

입력

  • A line with three space-separated integers $n$ $w$ and $h$ $(1 \leq n\leq 1000, 1 \leq w,h \leq 100),ドル indicating the number of locks, and the width and height of the key and locks.
  • $n$ locks, where each lock consists of $h$ lines of $w$ characters "#" or ".".
  • $h$ lines of $w$ character "#" or ".", representing the key.

출력

A single integer, the number of locks the given key fits in.

제한

예제 입력 1

1 20 5
....................
....................
....................
####################
....................
....................
....................
....................
####################
....................

예제 출력 1

0

예제 입력 2

3 20 5
....................
...................#
..................##
....###..##..##.####
####################
....................
...................#
..........#........#
....###..##..##.#..#
####################
....................
...................#
..##...............#
..#####..##..##.#..#
####################
####################
.....###...########.
......#.....###..#..
....................
....................

예제 출력 2

1

힌트

출처

University > Delft University of Technology > Sjaars Kampioenschap Programmeren 2015 G번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /