Problem:

Finding a Word

Write a program which reads a word W and a text T, and prints the number of word W which appears in text T

  T consists of string Ti separated by space characters and newlines. Count the number of Ti which equals to W. The word and text are case insensitive.

Constraints

  
The length of W ≤ 10

  
W consists of lower case letters

The length of T in a line ≤ 1000

Input

  In the first line, the word W is given. In the following lines, the text T is given separated by space characters and newlines.

"END_OF_TEXT" indicates the end of the text.

Output

  Print the number of W in the text.

Sample Input

computer
Nurtures computer scientists and highly-skilled computer engineers
who will create and exploit "knowledge" for the new era.
Provides an outstanding computer environment.
END_OF_TEXT

Sample Output

3



Sample input:
computer
Nurtures computer scientists and highly-skilled computer engineers
who will create and exploit "knowledge" for the new era.
Provides an outstanding computer environment.
END_OF_TEXT


Sample output:
3

Submission status: Wrong Answer

Solution code:
def myfindall(s,ps):
    matchlist =[]
    while True:
        tmp = s.find(ps)
        if tmp < 0 :
            break
        if len(matchlist)>0:
            matchlist.append(tmp+matchlist[-1]+1)
        else:
            matchlist.append(tmp)
        s = s[tmp+1:]
    return matchlist

findstr = raw_input().strip()
findstr = findstr.lower()
inlist = []
while True:
    tmpstr = raw_input().strip()
    # print tmpstr
    if tmpstr == "END_OF_TEXT":
        break
    inlist.append(tmpstr)
instr = "".join(inlist)
instr = instr.lower()
print len(myfindall(instr,findstr))

Submission status: Wrong Answer

Solution code:
def myfindall(s,ps):
    matchlist =[]
    while True:
        tmp = s.find(ps)
        if tmp < 0 :
            break
        if len(matchlist)>0:
            matchlist.append(tmp+matchlist[-1]+1)
        else:
            matchlist.append(tmp)
        s = s[tmp+1:]
    return matchlist

findstr = raw_input().strip()
findstr = findstr.lower()
inlist = []
while True:
    tmpstr = raw_input().replace("\r"," ")
    # print tmpstr
    if tmpstr == "END_OF_TEXT":
        break
    inlist.append(tmpstr)
instr = "".join(inlist)
instr = instr.lower()
print len(myfindall(instr,findstr))

Submission status: Wrong Answer

Solution code:
w = input()
T = str()

while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    T += s

print(T.count(w))

Submission status: Wrong Answer

Solution code:
w = input().lower()
T = str()

while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    T += s.lower()

print(T.count(w))

Submission status: Wrong Answer

Solution code:
# coding: utf-8

# ????´¢????±? W
target_word = input()
# ??????
words = []
while (1):
    input_text = input().strip()
    if (input_text == 'END_OF_TEXT'):
        break
    words.extend(input_text.split())

counter = 0
for w in words:
    if (w == target_word):
        counter += 1

print(counter)

Submission status: Wrong Answer

Solution code:
# coding: utf-8

# ????´¢????±? W
target_word = input().lower()
# ??????
words = []
while (1):
    input_text = input().strip()
    if (input_text == 'END_OF_TEXT'):
        break
    words.extend(input_text.split())

counter = 0
for w in words:
    if (w == target_word.lower()):
        counter += 1

print(counter)

Submission status: Wrong Answer

Solution code:
w = input().lower()
T = str()

while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    T += s.lower()

print(T.split().count(w))

Submission status: Wrong Answer

Solution code:
W = raw_input()

S = []
while True:
    tmp = raw_input()
    if tmp == "END_OF_TEXT":
        break
    else:
        S.append(tmp)
    
cnt = 0
for i in range(len(S)):
    if W in S[i]:
        cnt += 1
        
print cnt

Submission status: Wrong Answer

Solution code:
W = raw_input()

S = []
while True:
    tmp = raw_input()
    if tmp == "END_OF_TEXT":
        break
    else:
        S.append(tmp)
    
cnt = 0
for i in range(len(S)):
    if W in S[i]:
        cnt += S[i].count(W)
        
print cnt

Submission status: Wrong Answer

Solution code:
W = raw_input()

S = []
while True:
    tmp = raw_input()
    if tmp == "END_OF_TEXT":
        break
    else:
        S.append(tmp)
    
cnt = 0
for i in range(len(S)):
    if W in S[i].lower():
        cnt += (S[i].lower()).count(W)
        
print cnt

Submission status: Wrong Answer

Solution code:
W = raw_input()

S = []

while True:
    tmp = map(str, raw_input().split())
    if tmp[0] == "END_OF_TEXT":
        break
    else:
        S.append(tmp)

cnt = 0
for i in range(len(S)):
    for j in range(len(S[i])):
        print S[i][j]
        if W == S[i][j].lower():
            cnt += 1

print cnt

Submission status: Wrong Answer

Solution code:
sentence=input()
snt=sentence.lower()
word=input()

cnt=sentence.count(word)
print(cnt)

Submission status: Wrong Answer

Solution code:
t = ''
w = input()
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    t += line
print(t.lower().count(w))

Submission status: Wrong Answer

Solution code:
w, count = input(), 0

while True:
    line = input()
    if line == 'END_OF_TEXT':
        break
    count += line.split().count(w)

print(count)

Submission status: Wrong Answer

Solution code:
import sys

printf = sys.stdout.write

word = []
for line in sys.stdin:
    word.append(line.strip("\n"))

ans = 0
for i in range(len(word) - 2):
    ans += word[i + 1].count(word[0])
print ans

Submission status: Wrong Answer

Solution code:
import sys

printf = sys.stdout.write

word = []
for line in sys.stdin:
    word.append((line.strip("\n")).lower())

ans = 0
for i in range(len(word) - 2):
    ans += word[i + 1].count(word[0])
print ans

Submission status: Wrong Answer

Solution code:
s=input()
cnt=0
while True:
	String=input()
	if String == 'END_OF_TEXT':
		break
	cnt+=String.count(s)
print(cnt)

Submission status: Wrong Answer

Solution code:
s=input()
cnt=0
while True:
	String=input()
	if String == 'END_OF_TEXT':
		break
	cnt+=String.lower().count(s)
print(cnt)

Submission status: Wrong Answer

Solution code:

w = input()
word_count = 0
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    word = line.split()
    word_count += word.count(w)
print(word_count)

Submission status: Wrong Answer

Solution code:

w = input().casefold()
word_count = 0
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    word = line.casefold()
    word = line.split()
    word_count += word.count(w)
print(word_count)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

import sys

word = str(raw_input())
count = 0;

while True:
    line = map(str, raw_input().split())
    for i in line:
        if i == "END_OF_TEXT":
            print count
            sys.exit()
        if i == word:
            count += 1

Submission status: Wrong Answer

Solution code:
w = raw_input()
s = 0
while True:
    t = raw_input()
    if t !=  "END_OF_TEXT":
        s += t.count(w)
    else :
        break

print s

Submission status: Wrong Answer

Solution code:
w = raw_input().upper()
s = 0
while True:
    t = raw_input().upper()
    if t !=  "END_OF_TEXT":
        s += t.count(w)
    else :
        break

print s

Submission status: Wrong Answer

Solution code:
w = raw_input().upper()
s = 0
while True:
    t = raw_input()
    if t !=  "END_OF_TEXT":
        s += t.upper().count(w)
    else :
        break

print s

Submission status: Wrong Answer

Solution code:
import sys

a = sys.stdin.readlines()
x = 0
for i in a:
    if i=="END_OF_TEXT":
        break
    else:
        if i.count(a[0].rstrip("\r\n")):
            x+=1
        else:
            x+=0
print x

Submission status: Wrong Answer

Solution code:
import sys
a = sys.stdin.readlines()
x = 0
for i in a:
    if i=="END_OF_TEXT":
        break
    else:
        if i.count(a[0].rstrip("\r\n")):
            x+=1
        else:
            x+=0
print x

Submission status: Wrong Answer

Solution code:
import sys
a = sys.stdin.readlines()
x = 0
for i in a:
    print i
    if i=="END_OF_TEXT":
        break
    else:
        if i.count(a[0].rstrip("\r\n")):
            x+=1
        else:
            x+=0
print x

Submission status: Wrong Answer

Solution code:
import sys

a = sys.stdin.readlines()

x = 0
for i in a:
    print i
    if i=="END_OF_TEXT":
        break
    else:
        if i.count(a[0].rstrip("\r\n")):
            x+=1
        else:
            x+=0
print x

Submission status: Wrong Answer

Solution code:
import sys

a = sys.stdin.readlines()
x = 0
for i in a:
    if i=="END_OF_TEXT":
        break
    else:
        x+=i.count(a[0].rstrip("\r\n"))
print x-1

Submission status: Wrong Answer

Solution code:
a = raw_input()
s = 0
while True:
    b = raw_input()
    if b == 'END_OF_TEXT':
        break
    s += b.count(a)
print s

Submission status: Wrong Answer

Solution code:
a = raw_input().lower()
s = 0
while True:
    b = raw_input()
    if b == 'END_OF_TEXT':
        break
    b = b.lower()
    s += b.count(a)
print s

Submission status: Wrong Answer

Solution code:
ans = 0
W = input().lower()
while(True):
    T = input().lower()
    if(T == 'end_of_text'): break
    for text in T.split():
        text = text.replace(',', '')
        text = text.replace('.', '')
        if(text == W): ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
ans = 0
W = input().lower()
while(True):
    T = input().lower()
    if(T == 'end_of_text'): break
    ans += T.split().count(W)
print(ans)

Submission status: Wrong Answer

Solution code:
w = raw_input()
s = 0

while 1:
    in_str = raw_input()
    if in_str == "END_OF_TEXT":
        break
    s += in_str.count(w)

print s

Submission status: Wrong Answer

Solution code:
w = raw_input().lower()
s = 0

while 1:
    in_str = raw_input().lower()
    if in_str == "end_of_text":
        break
    s += in_str.count(w)

print s

Submission status: Wrong Answer

Solution code:
w = raw_input().lower()
s = 0

while 1:
    in_str = raw_input()
    if in_str == "END_OF_TEXT":
        break
    s += in_str.lower().count(w)

print s

Submission status: Wrong Answer

Solution code:
w = input()
t = ''
while(True):
    row = input()
    if row == 'END_OF_TEXT':
        break
    t += row

print(t.count(w))

Submission status: Wrong Answer

Solution code:
w = input()
t = ''
while(True):
    row = input()
    if row == 'END_OF_TEXT':
        break
    t += row

print(t.split().count(w))

Submission status: Wrong Answer

Solution code:
w = input()
t = ''
while(True):
    row = input()
    if row == 'END_OF_TEXT':
        break
    t += row + '\n'

print(t.split().count(w))

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
#   ??????????????????
t = "".join(t).split()
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i] == w:
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
#   ??????????????????
t = "".join(t).split()
print(t)
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i].find(w) != -1 :
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
    t += " "
#   ??????????????????
t = "".join(t).split(" ")
print(t)
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i].find(w) != -1 :
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
    t += " "
#   ??????????????????
t = "".join(t).split(" ")
#   print(t)
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i].find(w) != -1 :
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
    t += " "
#   ??????????????????
t = "".join(t).split(" ")
#   print(t)
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i] == w:
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
#   1???????????? W ??¨?????? T ,T ??????????????? W ?????°???????????????????????°??????
import sys
#   ??????W?????????
w = input()
#   ??????T?????????
t = []
#   ??????T?????????
while 1:
    temp = input()
    if temp == "END_OF_TEXT":
        break
    t += temp
    t += " "
#   ??????????????????
t = "".join(t).split(" ")
#   print(t)
#   ??????T???????????¨????????????W????????????????????????
count = 0
for i in range(len(t)):
    if t[i].strip(".") == w:
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
# 19-String-Finding_a_Word.py

# ?????????????´¢
# ??????????????? W ??¨?????? T ????????????????????????T ??????????????? W ?????°???????????????????????°?????????????????????????????????
# ?????? T ????????????????????????????????????????????§????????????????????????????????? Ti ??¨????????????
# ???????????? Ti ?????????????????? W ??¨??????????????????????????°??????????????????
# ???????????§????????¨?°???????????????\???????????????

# Constraints
# W????????????????????????10????¶????????????????
# T??????????????????????????????????????????1000????¶????????????????

# Input
# ?????????????????? W ????????????????????????
# ?¶???????????????°????????????????????£??????????????????????????????
# END_OF_TEXT ??¨??????????????????????????????????????????????????????

# Output
# ?????? W ?????°???????????????????????????

# Sample Input
# computer
# Nurtures computer scientists and highly-skilled computer engineers
# who will create and exploit "knowledge" for the new era.
# Provides an outstanding computer environment.
# END_OF_TEXT

# Sample Output
# 3
# Note

import re

count=0

w = input().lower()

while 1:
	string = input()
	if string=="END_OF_TEXT":
		break;

	string=string.split()
	for i in string:
		count += w==i

print(count)

Submission status: Wrong Answer

Solution code:
W = input()
T = ''
count = 0
while T != "END_OF_TEXT":
    T = input()
    count += T.split().count(W)

print(count)

Submission status: Wrong Answer

Solution code:
W = input().upper()
T = ''
count = 0
while T != "END_OF_TEXT":
    T = input().upper()
    count += T.split().count(W)

print(count)

Submission status: Wrong Answer

Solution code:
W = input().upper()
T = ''
count = 0
T = input().upper()
while T != "END_OF_TEXT":
    count += T.split().count(W)
    T = input().upper()
print(count)

Submission status: Wrong Answer

Solution code:
W = input().upper()
T = ''
count = 0
T = input().upper()#.split()
#print(T)
while T != 'END_OF_TEXT':
    T_list = T.split()
    for i in range(len(T_list)):
        #print(T_list,end="")
        if W == T_list[i]:
            count += 1
            #print("{0}".format(T_list[i]),end="")
    #count += T.split().count(W)
    #print()
    T = input().upper()#.split()
    #print(T)
print(count)

Submission status: Wrong Answer

Solution code:
W = input().upper()
count = 0
T = input().upper()
#print(T)
while T != 'END_OF_TEXT':
    for i in T.split():
        if i == W:
            count += 1
    T = input().upper()
    #print(T)

print(count)

Submission status: Wrong Answer

Solution code:
W = input()
count = 0
T = input().upper()
#print(T)
while T != 'END_OF_TEXT':
    for i in T.split():
        if i == W:
            count += 1
    T = input().upper()
    #print(T)

print(count)

Submission status: Wrong Answer

Solution code:
W=input()
cnt=0
while True:
    T=input()
    if T=='END_OF_TEXT': break
    cnt += T.split().count(W)
print(cnt)

Submission status: Wrong Answer

Solution code:
import sys
import math

def str_input():
    S = raw_input()
    if S[len(S)-1] == "\r":
        return S[:len(S)-1]
    return S

W = str_input()

cnt = 0
while 1:
    S = str_input()

    if (S == "END_OF_TEXT"):
        break

    cnt += S.count(W)

print cnt

Submission status: Wrong Answer

Solution code:
import sys
import math

def str_input():
    S = raw_input()
    if S[len(S)-1] == "\r":
        return S[:len(S)-1]
    return S

W = str_input()

cnt = 0
while 1:
    S = str_input()

    if (S == "END_OF_TEXT"):
        break

    for i in xrange(len(S)-len(W)+1):
        if W == S[i:i+len(W)]:
            cnt += 1

print cnt

Submission status: Wrong Answer

Solution code:
import sys
import math

def str_input():
    S = raw_input()
    if S[len(S)-1] == "\r":
        return S[:len(S)-1]
    return S

W = str_input()

cnt = 0
while 1:
    S = str_input().lower()

    if (S == "END_OF_TEXT".lower()):
        break

    cnt += S.count(W)

print cnt

Submission status: Wrong Answer

Solution code:
import sys
import math

def str_input():
    S = raw_input()
    if S[len(S)-1] == "\r":
        return S[:len(S)-1]
    return S

W = str_input()

cnt = 0
while 1:
    S = str_input()

    if (S == "END_OF_TEXT"):
        break

    S = S.lower()

    cnt += S.count(W)

print cnt

Submission status: Wrong Answer

Solution code:
W=input().lower()
cnt=0
while True:
    T=input()
    if T=='END_OF_TEXT': break
    cnt += T.lower().count(W)
print(cnt)

Submission status: Wrong Answer

Solution code:
import sys

match = input().lower()

s = str()
for line in sys.stdin:
	s += line.lower()

print(s.count(match))

Submission status: Wrong Answer

Solution code:
import sys

match = input().lower()

s = str()
for line in sys.stdin:
	s += line.lower()
print(s)
print(s.split().count(match))

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0

while True:
	line=raw_input().split(" ")
	if line[0]=="END_OF_TEXT":
		try:
			test=line[1]
		except:
			print ct
			break
	for i in line:
		if i==target:
			ct+=1

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0

while True:
	line=raw_input().split(" ")
	if line[0]=="END_OF_TEXT":

		print ct
		break
	for i in line:
		if i==target:
			ct+=1

Submission status: Wrong Answer

Solution code:
w = input().lower()
cnt = 0
while True:
    str = input()
    if str == "END_OF_TEXT":
        break
    else:
        cnt += str.lower().count(w)
print(cnt)

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0

while True:
	line=raw_input().split(" ")
	if line[0]=="END_OF_TEXT":
		#try:
			#test=line[1]
		#except:
			print ct
			break
	for i in line:
		if i==target:
			ct+=1

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0
flag=0
while True:
	line=raw_input().split(" ")
	for i in line:
		if i==target:
			ct+=1
		elif i=="END_OF_TEXT":
			print ct
			flag=1
	if flag==1:
		break

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0
flag=0
while True:
	line=raw_input().split(" ")
	for i in line:
		if i.lower()==target.lower:
			ct+=1
		elif i.upper()=="END_OF_TEXT":
			print ct
			flag=1
	if flag==1:
		break

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0
flag=0
while True:
	line=raw_input().split(" ")
	for i in line:
		if i.lower()==target.lower:
			ct+=1
		elif i.lower()=="end_of_text":
			print ct
			flag=1
	if flag==1:
		break

Submission status: Wrong Answer

Solution code:
target=raw_input()
ct=0
flag=0
while True:
	line=raw_input().split(" ")
	for i in line:
		if i.lower()==target.lower():
			ct+=1
		elif i.upper()=="END_OF_TEXT":
			print ct
			flag=1
	if flag==1:
		break

Submission status: Wrong Answer

Solution code:

W = input()
T = ""
while True:
    x = input()
    if x == "END_OF_TEXT":
        break
    T += x + " "


num = 0
for t in T.split():
    if t == W:
        num += 1

print(num)

Submission status: Wrong Answer

Solution code:
import re

W = input()

T = ""
while True:
    x = input()
    if x == "END_OF_TEXT":
        break
    T += x + " "

print(T)
num = 0
for t in re.split(r'\s|"|,|\.', T):
    if t == W:
        num += 1

print(num)

Submission status: Wrong Answer

Solution code:
import re

W = input()

T = ""
while True:
    x = input()
    if x == "END_OF_TEXT":
        break
    T += x + " "

print(T)
num = 0
for t in filter(lambda w: len(w) > 0, re.split(r'\s|"|,|\.', T)):
    if t == W:
        num += 1

print(num)

Submission status: Wrong Answer

Solution code:
w = input()

count = 0 # ????????????????????´?????°.
while True:
	line = input()

	if line == "END_OF_TEXT":
		break

	for word in line.split():
		if word == w:
			count += 1

print(count)

Submission status: Wrong Answer

Solution code:
w = input()
t = ""
while True:
    _ = input()
    if(_ == "END_OF_TEXT"):
        break
    t += _

print(t.lower().count(w.lower()))

Submission status: Wrong Answer

Solution code:
w = input()
t = ""
while True:
    _ = input()
    if(_ == "END_OF_TEXT"):
        break
    t += _

print(t.lower().split().count(w.lower()))

Submission status: Wrong Answer

Solution code:
word = input()
cnt = 0
while True:
	sent = input().split()
	if sent[0] == 'END_OF_TEXT':
		break
	if word in sent:
		cnt += sent.count(word)
print(cnt)

Submission status: Wrong Answer

Solution code:
word = input().lower()
cnt = 0
while True:
	sent = input().lower().split()
	if sent[0] == 'end_of_text':
		break
	if word in sent:
		cnt += sent.count(word)
print(cnt)

Submission status: Wrong Answer

Solution code:
W = input()
count = 0
while True:
    line = input()
    if line == 'END_OF_TEXT':
        break
    for s in line.split():
        if s == W:
            count += 1
print(count)

Submission status: Wrong Answer

Solution code:
W = input()

count = 0
while True:
    line = input()
    if line == 'END_OF_TEXT':
        break

    for s in line.split():
        if s == W:
            count += 1

print(count)

Submission status: Wrong Answer

Solution code:
W = input().lower()

count = 0
while True:
    line = input()
    if line == 'END_OF_TEXT':
        break

    for s in line.split():
        if s == W:
            count += 1

print(count)

Submission status: Wrong Answer

Solution code:
w = input().lower()

t = ""
while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    t += s.lower()

print(t.count(w))

Submission status: Wrong Answer

Solution code:
w = input().lower()
t = ""
while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    t += s.lower()
print(t.split().count(w))

Submission status: Wrong Answer

Solution code:
w = input().lower()
t = []
while True:
    s = input()
    if s == "END_OF_TEXT":
        break
    for word in s.split():
        t.append(word)
print(t.count(w))

Submission status: Wrong Answer

Solution code:
s = ''
w = input()
while True:
    inp = input()
    if inp == 'END_OF_TEXT':
        break
    s += inp
print(s.count(w))

Submission status: Wrong Answer

Solution code:
s = ''
w = input().lower()
while True:
    inp = input()
    if inp == 'END_OF_TEXT':
        break
    s += inp.lower()
print(s.count(w))

Submission status: Wrong Answer

Solution code:
s = ''
w = input().lower()
while True:
    inp = input()
    if inp == 'END_OF_TEXT':
        break
    s += ' ' + inp.lower()
print(s.count(w))

Submission status: Wrong Answer

Solution code:
import sys

w = input()
s = []
cnt = 0

for i in sys.stdin.readlines():
    if i == 'END_OF_TEXT\n':
        break
    for j in [x.strip('.') for x in i.split()]:
        s.append(j)

for i in s:
    if w == i:
        cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
W = input()
num = 0
for line in input():
    if line == 'END_OF_TEXT':
        break
    for word in line.split():
        if word.lower() == W.lower():
            num += 1
print(num)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
w = raw_input()
c = 0
while 1:
 t = raw_input()
 if t=="END_OF_TEXT": break
 tt = t.split()
 c += tt.count(w)
print c

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
w = raw_input().upper()
c = 0
while 1:
 t = raw_input().upper()
 if t=="END_OF_TEXT": break
 c += t.split().count(w)
print c

Submission status: Wrong Answer

Solution code:
import sys

w = sys.stdin.readline().strip().lower()

cnt = 0
while True:
    line = sys.stdin.readline().strip()
    if line == 'END_OF_TEXT':
        break
        
    words = line.split(' ')
    for i in words:
        if i == w:
            cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
import sys

w = sys.stdin.readline().strip().lower()

cnt = 0
while True:
    line = sys.stdin.readline().strip()
    if line == 'END_OF_TEXT':
        break
        
    words = line.split(' ')
    for i in words:
        if i == w.lower():
            cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
word = input()
s = str()
while True:
    line = input()
    if line == 'END_OF_TEXT':
        break
    s += line.lower()
print(s.count(word))

Submission status: Wrong Answer

Solution code:
s = input()
n = 0
while True:
    q = input()
    if q == "END_OF_TEXT":
        break
    n += q.count(s)
print(n)

Submission status: Wrong Answer

Solution code:
s = input().lower()
n = 0
while True:
    q = input()
    if q == "END_OF_TEXT":
        break
    q = q.lower()
    n += q.count(s)
print(n)

Submission status: Wrong Answer

Solution code:
s = raw_input()
s = s[:-1]
cnt = 0
while True:
	text = raw_input()
	if 'END_OF_TEXT' == text.strip():
		break
	text = text.lower()
	while text.find(s)>=0:
		text = text[text.find(s)+len(s):]
		cnt += 1
print cnt

Submission status: Wrong Answer

Solution code:
s = raw_input()
s = s[:-1]
s = s.lower()
cnt = 0
while True:
	text = raw_input()
	if 'END_OF_TEXT' == text.strip():
		break
	text = text.lower()
	while text.find(s)>=0:
		text = text[text.find(s)+len(s):]
		cnt += 1
print cnt

Submission status: Wrong Answer

Solution code:
s = raw_input()
s = s.lower().strip()
cnt = 0
while True:
	text = raw_input()
	if 'END_OF_TEXT' == text.strip():
		break
	text = text.lower()
	while text.find(s)>=0:
		text = text[text.find(s)+len(s):]
		cnt += 1
print cnt

Submission status: Wrong Answer

Solution code:
word = raw_input()
count = 0

while 1:
    line = raw_input()
    if line == "END_OF_TEXT":
        break
    for i in range(len(line)):
        if i + len(word) < len(line):
            if word == line[i:i+len(word)]:
                count += 1

print(count)

Submission status: Wrong Answer

Solution code:
word = raw_input().lower()
count = 0

while 1:
    line = raw_input()
    if line == "END_OF_TEXT":
        break
    line = line.lower()
    for i in range(len(line)):
        if i + len(word) < len(line):
            if word == line[i:i+len(word)]:
                count += 1

print(count)

Submission status: Wrong Answer

Solution code:
word = raw_input().lower()
count = 0

while 1:
    line = raw_input()
    if line == "END_OF_TEXT":
        break
    line = line.lower()
    for i in range(len(line)):
        if i + len(word) < len(line) + 1:
            if word == line[i:i+len(word)]:
                count += 1

print(count)

Submission status: Wrong Answer

Solution code:
W = str(raw_input())

count = 0

while(1):
    T = map(str, raw_input().split())
    if T[0] == "END_OF_TEXT":
        break
    else:
        for i in range(len(T)):
            if W == T[i]:
                count += 1
print count

Submission status: Wrong Answer

Solution code:
W = raw_input()
t= ""
while True:
    T = raw_input()
    if T == "END_OF_TEXT":
        break;
    else:
        t += T
print(t.count(W))

Submission status: Wrong Answer

Solution code:
W = raw_input()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t

print(t.count(W),)

Submission status: Wrong Answer

Solution code:
W = raw_input()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t

print t.count(W),

Submission status: Wrong Answer

Solution code:
W = raw_input().lower()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t.lower()

print(t.count(W))

Submission status: Wrong Answer

Solution code:
W = raw_input().lower()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t.lower()

print(T.count(W))

Submission status: Wrong Answer

Solution code:
W = raw_input().lower()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t.lower() + "."

print(T.count(W))

Submission status: Wrong Answer

Solution code:
W = raw_input().lower()
T= ""
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break;
    else:
        T += t.lower() + "K"

print(T.count(W))

Submission status: Wrong Answer

Solution code:
W = raw_input().lower()
T= []
while True:
    t = raw_input()
    if t == "END_OF_TEXT":
        break
    else:
        T += t.lower().split()
print(T)
print(T.count(W))

Submission status: Wrong Answer

Solution code:
import sys
w = input()
print(sys.stdin.read().count(w))

Submission status: Wrong Answer

Solution code:
import sys
w = input()
print(sys.stdin.read().lower().count(w))

Submission status: Wrong Answer

Solution code:
word = input()
count = 0
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    words = line.split()
    for w in words:
        if w == word:
            count += 1
print(count)

Submission status: Wrong Answer

Solution code:
word = input().lower
count = 0
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    words = line.lower().split()
    for w in words:
        if w == word:
            count += 1
print(count)

Submission status: Wrong Answer

Solution code:
word = input().lower()
count = 0
while True:
    line = input()
    if line == "END_OF_TEXT":
        break
    print(line.lower())
    words = line.lower().split()
    for w in words:
        if w == word:
            count += 1
print(count)

Submission status: Wrong Answer

Solution code:
a = []
while 1:
 s = input()
 if s == 'END_OF_TEXT':
  break
 else:
  a.append(s)

print(a.count(a[0]) - 1)

Submission status: Wrong Answer

Solution code:
a = []
while 1:
 s = input()
 if s == 'END_OF_TEXT':
  break
 else:
  s = list(s.split('.'))
  s = list(s[0].split())
  a.append(s)

print(a.count(a[0]) - 1)

Submission status: Wrong Answer

Solution code:
a = []
while 1:
 s = input()
 if s == 'END_OF_TEXT':
  break
 else:
  s = list(s.split('.'))
  s = ' '.join(s)
  s = list(s.split())
  a.append(s)

print(a.count(a[0]) - 1)