Problem:


Score : 100 points

Problem Statement

You will be given a string S of length 3 representing the weather forecast for three days in the past.

The i-th character (1 \leq i \leq 3) of S represents the forecast for the i-th day. S, C, and R stand for sunny, cloudy, and rainy, respectively.

You will also be given a string T of length 3 representing the actual weather on those three days.

The i-th character (1 \leq i \leq 3) of S represents the actual weather on the i-th day. S, C, and R stand for sunny, cloudy, and rainy, respectively.

Print the number of days for which the forecast was correct.

Constraints

S and T are strings of length 3 each.

S and T consist of S, C, and R.

Input

Input is given from Standard Input in the following format:

S
T

Output

Print the number of days for which the forecast was correct.

Sample Input 1

CSS
CSR

Sample Output 1

2

For the first day, it was forecast to be cloudy, and it was indeed cloudy.

For the second day, it was forecast to be sunny, and it was indeed sunny.

For the third day, it was forecast to be sunny, but it was rainy.

Thus, the forecast was correct for two days in this case.

Sample Input 2

SSR
SSR

Sample Output 2

3

Sample Input 3

RRR
SSS

Sample Output 3

0



Sample input:
CSS
CSR


Sample output:
2

Submission status: Accepted

Solution code:
s = input()
t = input()
count = 0
if s[0] == t[0]:
  count += 1
if s[1] == t[1]:
  count += 1
if s[2] == t[2]:
  count += 1
print(count)

Submission status: Accepted

Solution code:
S = input()
T = input()

count = 0
forecast1 = S[0]
result1 = T[0]

if forecast1 == result1:
    count = count + 1


forecast2 = S[1]
result2 = T[1]

if forecast2 == result2:
    count = count + 1

    
forecast3 = S[2]
result3 = T[2]

if forecast3 == result3:
    count = count + 1

print(count)

Submission status: Accepted

Solution code:
count = 0
S= input()
T= input()
forecast1 = S[0]
result1 =T[0]

if forecast1 == result1:
    count = count + 1

forecast2 = S[1]
result2 = T[1]

if forecast2 == result2:
    count = count + 1

forecast3 = S[2]
result3 = T[2]

if forecast3 == result3:
    count = count + 1

print(count)

Submission status: Accepted

Solution code:
S = input()
T = input()

# 手順0
count = 0  # 予報が的中した回数

# 手順1: 1日目だけの話にもちこむ
forecast1 = S[0] # 1日目の天気予報
result1 = T[0]  #  1日目の実際の結果

if forecast1 == result1:
    count = count + 1

# 手順2: 2日目だけの話にもちこむ
forecast2 = S[1] # 2日目の天気予報
result2 = T[1] # 2日目の実際の結果

if forecast2 == result2:
    count = count + 1

# 手順3: 3日目の話
forecast3 = S[2]
result3 = T[2]

if forecast3 == result3:
    count = count + 1

print(count)

Submission status: Accepted

Solution code:
s=input()
t=input()

ans=0
i=0
while i<len(s):

    if s[i]==t[i]:
        ans+=1

    i+=1
    
print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()

cnt=0
for i in range(3):
    if s[i]==t[i]:
        cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()

count = 0
for i in range(len(S)):
  if S[i] == T[i]:
    count += 1
print(count)

Submission status: Accepted

Solution code:
t=input()
s=input()
cor=0
for i in range(3):
  if t[i]==s[i]:
    cor+=1
print(cor)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
a = 0
for i in range(3):
    if s[i] == t[i]:
        a += 1
print(a)

Submission status: Accepted

Solution code:
S = input()
T = input()
print(sum([1 if s == t else 0 for s, t in zip(S, T)]))

Submission status: Accepted

Solution code:
S=input()
T=input()
count=0
if S[0]==T[0]:
  count=count+1
if S[1]==T[1]:
  count=count+1
if S[2]==T[2]:
  count=count+1
print(count)

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().strip()
def mapint(): return map(int, input().split())
sys.setrecursionlimit(10**9)

S = str(input())
T = str(input())
ans = 0
for i in range(3):
    if S[i]==T[i]:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
print(sum(i == j for i, j in zip(*open(0).read().split())))

Submission status: Accepted

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

ans = 0
for i in range(3):
  if S[i] == T[i]:
    ans +=1
    
print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()
ans=0
for i in range(3):
  if s[i]==t[i]:
    ans=ans+1
print(ans)

Submission status: Accepted

Solution code:
S = input()
T = input()
Count = 0
for SC,TC in zip(S,T):
    if SC == TC:
        Count += 1
print(Count)

Submission status: Accepted

Solution code:
import sys
input = lambda: sys.stdin.readline().rstrip()

def main():
    s = list(input())
    t = list(input())
    ans = 0
    for a, b in zip(s, t):
        if a == b:
            ans += 1
    print(ans)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

s = str(input())
t = str(input())

counter = 0

for i in range(len(s)):
    if s[i] == t[i]:
        counter = counter + 1

print(counter)

Submission status: Accepted

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

s = str(input())
t = str(input())

counter = 0

counter = counter + 1 if s[0] == t[0] else counter
counter = counter + 1 if s[1] == t[1] else counter
counter = counter + 1 if s[2] == t[2] else counter

print(counter)

Submission status: Accepted

Solution code:
S = list(input())
T = list(input())
count = 0
for i,j in zip(S,T):
    if(i==j):
        count += 1 
print(count)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
f = 0

for i,j in zip(s,t):
    if i==j:
        f += 1
print(f)

Submission status: Accepted

Solution code:
s = input()
t = input()

count = 0
for i in range(3):
    if s[i] == t[i]:
        count += 1

print(count)

Submission status: Accepted

Solution code:
S=input()
T=input()

ans=0

for i in range(3):
    if S[i]==T[i]:
        ans+=1

print(ans)

Submission status: Accepted

Solution code:
# Template 1.0
import sys, re
from decimal import *
from collections import deque, defaultdict, Counter, OrderedDict
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, floor, trunc, log
from heapq import heappush, heappop, heapify, nlargest, nsmallest
def STR(): return list(input())
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def list2d(a, b, c): return [[c] * b for i in range(a)]
def sortListWithIndex(listOfTuples, idx):   return (sorted(listOfTuples, key=lambda x: x[idx]))
def sortDictWithVal(passedDic):
    temp = sorted(passedDic.items(), key=lambda kv: (kv[1], kv[0]))
    toret = {}
    for tup in temp:
        toret[tup[0]] = tup[1]
    return toret
def sortDictWithKey(passedDic):
    return dict(OrderedDict(sorted(passedDic.items())))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

s = input()
t = input()
ans = 0
for i in range(3):
    if(s[i]==t[i]):
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
s=list(input())
t=list(input())
nmb=[0, 1, 2]
cnt=0
for i in nmb:
    if s[i]==t[i]:
        cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()

c = 0

for i in range(len(S)):
  if S[i] == T[i]:
    c +=1
print(c)

Submission status: Accepted

Solution code:
import sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


def main():
    S = readline().strip()
    T = readline().strip()
    
    ans = 0
    for s, t in zip(S, T):
        if s == t:
            ans += 1
            
    print(ans)
    return


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
S = input()
T = input()
count = 0
if S[0] == T[0]:
    count = count+1
if S[1] == T[1]:
    count = count+1
if S[2] == T[2]:
    count = count+1
print(count)

Submission status: Accepted

Solution code:
S = input()
T = input()
count = 0
if S[0] == T[0]:
    count += 1
if S[1] == T[1]:
    count += 1
if S[2] == T[2]:
    count += 1

print(count)

Submission status: Accepted

Solution code:
s = input("")
t = input("")
correct = 0
for i in range(len(s)):
  if s[i] == t[i]:
    correct+=1
print(correct)

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(3):
  if s[i] == t[i]:
    ans +=1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()

cnt = 0
for i in range(3):
    if s[i]==t[i]:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
S = list(str(input()))
T = list(str(input()))
a = 0
for i in range(3):
  if S[i] == T[i]:
    a += 1
print(a)

Submission status: Accepted

Solution code:
s=input()
t=input()
cnt=0
for i in range(3):
    if s[i]==t[i]:
        cnt+=1

print(cnt)

Submission status: Accepted

Solution code:
import sys

sys.setrecursionlimit(10 ** 8)

input = sys.stdin.readline


def main():
    S = input().strip()
    T = input().strip()

    ans = 0
    for i in range(3):
        if S[i] == T[i]:
            ans += 1

    print(ans)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
# A - Tenki
def main():
    s = list(input())
    t = list(input())
    cnt = 0

    for i in range(3):
        if s[i] == t[i]:
            cnt += 1
    print(cnt)

if __name__ ==  "__main__":
    main()

Submission status: Accepted

Solution code:
a = input()
b = input()
 
print(len([i for i in range(3) if a[i] == b[i]]))

Submission status: Accepted

Solution code:
days = list(str(input()))
days_real = list(str(input()))
count = 0
for i in range(3):
  if days[i] == days_real[i]:
    count += 1
print(count)

Submission status: Accepted

Solution code:
s = input()
t = input()

count = 0
for i in range(3):
    if s[i] == t[i]:
        count += 1

print(count)

Submission status: Accepted

Solution code:
def main():
    s = list(str(input()))
    t = list(str(input()))
    count = 0
    for i in range(3):
        if s[i] == t[i]:
            count += 1
    print(count)
main()

Submission status: Accepted

Solution code:
str1 = input()
str2 = input()
ans = 0
for i in range(0, 3):
  if str1[i] == str2[i]: ans += 1
    
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(3):
    if s[i] == t[i]: ans += 1
print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()
ans=0
for i in range(0,3):
  if s[i]==t[i]:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
print(sum(s==t for s,t in zip(input(),input())))

Submission status: Accepted

Solution code:
print(sum([1 for s,t in zip(input(),input()) if s==t]))

Submission status: Accepted

Solution code:
mod=10**9+7
import math
import sys
from collections import deque
import heapq
import copy
import itertools
from itertools import permutations
from itertools import combinations
import bisect
def mi() : return map(int,sys.stdin.readline().split())
def ii() : return int(sys.stdin.readline().rstrip())
def i() : return sys.stdin.readline().rstrip()

a=i()
b=i()
c=0
for i in range(3):
  if a[i]==b[i]:
    c+=1
print(c)

Submission status: Accepted

Solution code:
def split(a): 
    return [char for char in a]    
pred=input()
real=input()
x=split(pred)
y=split(real)
c=0
if x[0]==y[0]:
    c+=1
if x[1]==y[1]:
    c+=1
if x[2]==y[2]:
    c+=1
print(c)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
count= 0
for i in range(3):
    if(s[i] == t[i]):
        count += 1

print(count)

Submission status: Accepted

Solution code:
S = input()
T = input()
cnt =0
for i in range(3):
    if S[i]==T[i]:
        cnt +=1
print(cnt)

Submission status: Accepted

Solution code:
s = input()
t = input()

count = 0

for i in range(3):
  if(s[i] == t[i]):
    count += 1

print(count)

Submission status: Accepted

Solution code:
import numpy as np
s = np.array(list(input()))
t = np.array(list(input()))
print(len(s[s==t]))

Submission status: Accepted

Solution code:
S = input()
T = input()
counter = 0
for i in range(3):
    if S[i] == T[i]:
        counter += 1
print(counter)

Submission status: Accepted

Solution code:
ST = [input(),input()]
ST = [int(i) for i in range(3) if ST[0][i] == ST[1][i]]
print(len(ST))

Submission status: Accepted

Solution code:
# 139 A

s = input()
t = input()
num = 0

for i in range(3):
    if s[i] == t[i]:
        num += 1
print(num)

Submission status: Accepted

Solution code:
S = input()
T = input()

print(len([i for i in range(3) if S[i] == T[i]]))

Submission status: Accepted

Solution code:
a = input()
b = input()
ans = 0
for i in range (0,3):
    if a[i] == b[i]:
        ans = ans + 1
print(ans)

Submission status: Accepted

Solution code:
pre = input()
re = input()
ten = 0
for i in range(3):
    if pre[i]==re[i]:
        ten += 1
print(ten)

Submission status: Accepted

Solution code:
a=input()
b=input()
ans=0
for i in range(3):
  ans+=(a[i]==b[i])
print(ans)

Submission status: Accepted

Solution code:
S = input()
T = input()

if S[0] == T[0] and S[1] == T[1] and S[2] == T[2]:
  print(3)
elif S[0] == T[0] and S[1] == T[1] and S[2] != T[2]: 
  print(2)
elif S[0] != T[0] and S[1] == T[1] and S[2] == T[2]: 
  print(2)
elif S[0] == T[0] and S[1] != T[1] and S[2] == T[2]: 
  print(2)
elif S[0] != T[0] and S[1] != T[1] and S[2] != T[2]: 
  print(0)
else:
  print(1)

Submission status: Accepted

Solution code:
s = input()
t = input()
cnt = 0
for i in range(3):
    if( s[i] == t[i]):
        cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
num = 0
for i in range(3):
    if(s[i] == t[i]):
        num = num + 1
print(num)

Submission status: Accepted

Solution code:
s = input()
t = input()
c = sum([ 1 for i,j in zip(s,t) if i == j])
print(c)

Submission status: Accepted

Solution code:
s = input()
t = input()
count = 0
for i in range(3):
    if s[i] == t[i]:
        count += 1
print(count)

Submission status: Accepted

Solution code:
def main():
    s = list(input())
    t = list(input())
    cnt = 0
    for i in range(3):
        if s[i] == t[i]:
            cnt += 1
    print(cnt)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(3):
	if s[i] == t[i]:
  		ans += 1
print(ans)

Submission status: Accepted

Solution code:
a1=input()
a2=input()
A1=list(a1)
A2=list(a2)
i=0
for x in A1:
    if x!='C' and x!='S' and x!='R':
        A1.remove(x)
for x in A2:
    if x!='C' and x!='S' and x!='R':
        A2.remove(x)
if len(A1)==len(A2)==3:   
    if A1[0]==A2[0]:
        i+=1
    if A1[1]==A2[1]:
        i+=1
    if A1[2]==A2[2]:
        i+=1
    print(i)

Submission status: Accepted

Solution code:
a=list(input())
b=list(input())
c=0
for i in range(3):
  if a[i]==b[i]:
    c+=1
print(c)

Submission status: Accepted

Solution code:
S=input()
T=input()
result=0
i=[]
n=[]
i.extend(S)
n.extend(T)
if i[0]==n[0]:
    result+=1
if i[1]==n[1]:
    result+=1
if i[2]==n[2]:
    result+=1
print(result)

Submission status: Accepted

Solution code:
a = input()
b = input()
c = 0
for i in range(3):
      if (a[i]==b[i]):
            c+=1

print(c)

Submission status: Accepted

Solution code:
S=input()
T=input()
PS=[S[i]==T[i] for i in range(3)]
print(sum(PS))

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0

for i, j in zip(s, t):
    if i == j:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
a=input()
b=input()
ans=0
for i in range(3):
    ans+=(a[i]==b[i])
print(ans)

Submission status: Accepted

Solution code:
S,T = open(0).read().split()
a = 0

if S[0]==T[0]:
  a+=1
if S[1]==T[1]:
  a+=1
if S[2]==T[2]:
  a+=1
  
print(a)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())

count = 0
for i in range(len(s)):
    count = count + 1 if s[i] == t[i] else count

print(count)

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(3):
    if s[i] == t[i]:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
a = input()
b = input()

ans = 0
for i in range(3):
  if a[i] == b[i]:
    ans += 1
    continue
print(ans)

Submission status: Accepted

Solution code:
def solve():
    s = input()
    t = input()
    count = 0
    for i, j in zip(s, t):
        if i == j:
            count += 1
    print(count)


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
ss=list(input())
tt=list(input())
res=0
for s,t in zip(ss,tt):
  if s==t:
    res+=1
print(res)

Submission status: Accepted

Solution code:
S = list(input())
T = list(input())
ctr = 0
for i in range (3):
  if S[i] == T[i]:
    ctr += 1
print(ctr)

Submission status: Accepted

Solution code:
s=list(input())
t=list(input())
a=0
for i in range(3):
    if s[i]==t[i]:
        a+=1
print(a)

Submission status: Accepted

Solution code:
s = str(input())
t = str(input())
count = 0
for i in range(3):
    if s[i] == t[i]:
        count += 1
print(count)

Submission status: Accepted

Solution code:
s=input()
t=input()
ans=0
for i in range(3):
	if s[i]==t[i]:
		ans+=1
print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()
c=0
for i in range(3):
    if s[i]==t[i]:
        c+=1

print(c)

Submission status: Accepted

Solution code:
s = input()
t = input()
res = list(map(lambda x: x[0] == x[1], zip(s, t)))
print(res.count(True))

Submission status: Accepted

Solution code:
s=0
A=input()
B=input()
for i in range(3):
  if A[i]==B[i]:
    s+=1
print(s)

Submission status: Accepted

Solution code:
s = input()
t = input()
count = 0

for i in range(3):
  if s[i] == t[i]:
    count += 1

print(count)

Submission status: Accepted

Solution code:
s = input()
t = input()
sum = (s[0]==t[0]) + (s[1]==t[1]) + (s[2]==t[2]) 
print(sum)

Submission status: Accepted

Solution code:
import numpy as np
N=input()
M=input()
ans = 0
for i in range(3):
  if N[i]==M[i]:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
count = 0
for i in range(3):
    if s[i] == t[i]:
        count += 1
print(count)

Submission status: Accepted

Solution code:
import sys, math
input = sys.stdin.readline
rs = lambda: input().strip()
ri = lambda: int(input())
rl = lambda: list(map(int, input().split()))
mod = 10**9 + 7

S = rs()
T = rs()

ans = 0
for i in range(3):
	if S[i] == T[i]:
		ans += 1
print(ans)

Submission status: Accepted

Solution code:
S = input()
T = input()

ans = 0
for i in range(3):
    if S[i] == T[i]:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
import sys
from collections import defaultdict
readline = sys.stdin.buffer.readline
#sys.setrecursionlimit(10**8)


def geta(fn=lambda s: s.decode()):
    return map(fn, readline().split())


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    s = gete()
    t = gete()

    ans = 0
    for i in range(3):
        if s[i] == t[i]: ans += 1

    print(ans)

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
S = input()
T = input()

a = 0
for i, j in zip(S, T):
    if i == j:
        a += 1
print(a)

Submission status: Accepted

Solution code:
import sys
a = []
for l in sys.stdin:
    a.append(l)
count = 0
for i in range(3):
  if a[0][i] == a[1][i]:
    count += 1
print(count)

Submission status: Accepted

Solution code:
s=input()
t=input()

counter=0
for i in range(3):
    if s[i] == t[i]:
        counter += 1
print(counter)

Submission status: Accepted

Solution code:
s=input()
t=input()
ans=0
for i in range(len(s)):
  if s[i]==t[i]:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
import sys
import math
def I():return int(sys.stdin.readline().replace("\n",""))
def I2():return map(int,sys.stdin.readline().replace("\n","").split())
def S():return str(sys.stdin.readline().replace("\n",""))
def L():return list(sys.stdin.readline().replace("\n",""))
def Intl():return [int(k) for k in sys.stdin.readline().replace("\n","").split()]
def Lx(k):return list(map(lambda x:int(x)*-k,sys.stdin.readline().replace("\n","").split()))

if __name__ == "__main__":
    s = S()
    t = S()
    cnt = 0
    for i in range(len(s)):
        if s[i] == t[i]:cnt += 1
    print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()

count = 0
for i in range(3):
    if S[i] == T[i]:
        count += 1

print(count)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
ans = 0
for i in range(3):
    if s[i] == t[i]:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
S,T=[input() for i in range(2)]
ans=0
for i in range(0,3):
  if S[i]==T[i]:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
sum = 0
for x in range(3):
  if s[x] == t[x]:
    sum += 1
print(sum)

Submission status: Accepted

Solution code:
def main():
    s = input()
    t = input()

    cnt = 0

    for i in range(3):
        if s[i] == t[i]:
            cnt += 1

    print(cnt)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
S = list(input())
T = list(input())
ans = 0

for i in range(3) :
    if S[i] == T[i] :
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
cnt = 0
for i in range(len(s)):
  if s[i] == t[i] :
    cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
S = list(input())
T = list(input())

count = 0

for i, _ in enumerate(S):
    if S[i] is T[i]:
        count += 1

print(count)

Submission status: Accepted

Solution code:
s = input()
r = input()
ans = 0
for i in range(3):
  if s[i] == r[i]:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()

if s[0] == t[0] and s[1] == t[1] and s[2] == t[2]:
  print(3)
elif (s[0] == t[0] and s[1] == t[1]) or (s[1] == t[1] and s[2] == t[2]) or (s[2] == t[2] and s[0] == t[0]):
  print(2)
elif s[0] == t[0] or s[1] == t[1] or s[2] == t[2]:
  print(1)
else:
  print(0)

Submission status: Accepted

Solution code:
s = input()
t = input()

ans = 0
for i,j in zip(s,t):
    if i == j:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
cnt = 0
for i in range(3):
    if s[i] == t[i]:
        cnt +=1
print(cnt)

Submission status: Accepted

Solution code:
s=input()
t=input()
a=0
for i in range(3):
  if s[i]==t[i]:
    a+=1
print(a)

Submission status: Accepted

Solution code:
S = input()
T = input()
c = 0
for i in range(3):
  if S[i]==T[i]:
    c += 1
print(c)

Submission status: Accepted

Solution code:
S = input()
T = input()
c = 0
if S[0] == T[0]:
    c = c + 1
if S[1] == T[1]:
    c = c + 1
if S[2] == T[2]:
    c = c + 1

print(c)

Submission status: Accepted

Solution code:
s=input()
t=input()
count=0
for i in range(3):
  if s[i]==t[i]:
    count += 1
print(count)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())

print(len([i for i in range(len(s)) if s[i] ==t[i]]))

Submission status: Accepted

Solution code:
import sys
from collections import defaultdict
readline = sys.stdin.buffer.readline
#sys.setrecursionlimit(10**8)


def geta(fn=lambda s: s.decode()):
    return map(fn, readline().split())


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    s = gete()
    t = gete()
    ans = 0
    for i in range(len(s)):
        if s[i] == t[i]:
            ans += 1

    print(ans)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
s = input()
t = input()
m = 0
for i in range(3):
    if s[i] == t[i]:
        m += 1
print(m)

Submission status: Accepted

Solution code:
s=list(input())
t=list(input())
cnt=0
for a,b in zip(s,t):
  if a==b:
    cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()

cnt = 0
for s, t in zip(S, T):
  if s == t:
    cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()
count = 0
for s, t in zip(S, T):
  if s == t:
    count += 1
print(count)

Submission status: Accepted

Solution code:
s=input()
t=input()
cnt=0
for i in range(len(s)):
  if s[i]==t[i]:
    cnt+=1
 
print(cnt)

Submission status: Accepted

Solution code:
s=input()
t=input()
c=0
for i in range(3):
    if s[i]==t[i]:
        c+=1
print(c)

Submission status: Accepted

Solution code:
S=input()
T=input()

ok=0

for i in range(3):
  if S[i]==T[i]:
    ok+=1
    
print(ok)

Submission status: Accepted

Solution code:
s = input()
t = input()

a = int(s[0] == t[0])
b = int(s[1] == t[1])
c = int(s[2] == t[2])

print(a+b+c)

Submission status: Accepted

Solution code:
Pre = input()
Truth = input()
count = 0
for a,b in zip(Pre,Truth):
    if a == b:
        count += 1
print(count)

Submission status: Accepted

Solution code:
s = input()
t = input()
res=0
for a,b in zip(s,t):
    if a==b:
        res+=1
print(res)

Submission status: Accepted

Solution code:
s = input()
t = input()
count = 0

if s[0] == t[0]:
    count = count + 1

if s[1] == t[1]:
    count = count + 1

if s[2] == t[2]:
    count = count + 1

print(count)

Submission status: Accepted

Solution code:
import sys

input = lambda: sys.stdin.readline().rstrip()


def solve():
    S = input()
    T = input()

    ans = 0
    for i in range(len(S)):
        if S[i] == T[i]:
            ans += 1

    print(ans)


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
s = input()
t = input()
print(sum([ss == tt for ss, tt in zip(s,t)]))

Submission status: Accepted

Solution code:
import sys
import decimal # 10進法に変換，正確な計算

def input():
    return sys.stdin.readline().strip()

def main():
    s = input()
    t = input()
    count = 0
    for i in range(3):
        if s[i] == t[i]:
            count += 1
    print(count)    
    
main()

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(len(s)):
  if s[i] == t[i]:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()
ans = 0
for i in range(3):
    if s[i] == t[i]:
        ans +=1
print(ans)

Submission status: Accepted

Solution code:
def main():
    s = input()
    t = input()
    c = 0
    for i in range(len(s)):
        if s[i] == t[i]:
            c += 1
    return c

if __name__ == "__main__":
    print(main())

Submission status: Accepted

Solution code:
a=input()
b=input()
ans=0
for i,j in zip(a,b):
    if i==j:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
a = []
for i in range(2):
    a.append(input())

c = 0
for i in range (3):
  if a[0][i] == a[1][i]:
    c += 1
print(c)

Submission status: Accepted

Solution code:
s=input()
t=input()
count=0
for i in range(len(s)):
    if s[i]==t[i]:
        count+=1
print(count)

Submission status: Accepted

Solution code:
S = input()
T = input()

ans = 0
for s,t in zip(list(S), list(T)):
    if s==t:
        ans += 1
        
print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()
count=0
for i in range(3):
    if s[i]==t[i]:
        count+=1
print(count)

Submission status: Accepted

Solution code:
# Python3 (3.4.3)
import sys
input = sys.stdin.readline

# -------------------------------------------------------------
# function
# -------------------------------------------------------------


# -------------------------------------------------------------
# main
# -------------------------------------------------------------
S = input().rstrip()
T = input().rstrip()

ans = 0
for i in range(3):
    if S[i] == T[i]:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
s = input()
t = input()

ans = 0
for i,data in enumerate(s):
  if s[i] == t[i]:
    ans += 1

print(ans)

Submission status: Accepted

Solution code:
S = input()
T = input()

hit = 0
for i in range(len(S)):
    if S[i] == T[i]:
        hit += 1

print(hit)

Submission status: Accepted

Solution code:
s = input()
t = input()

cnt = 0
for i in range(3):
    if s[i] == t[i]:
        cnt += 1
        
print(cnt)

Submission status: Accepted

Solution code:
from sys import stdin, setrecursionlimit


def main():
    input = stdin.buffer.readline
    s = list(input()[:-1].decode())
    t = list(input()[:-1].decode())

    ans = 0

    for i in range(3):
        if s[i] == t[i]:
            ans += 1

    print(ans)


if __name__ == "__main__":
    setrecursionlimit(10000)
    main()

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
count = 0

for i in range(3):
  if s[i] == t[i]:
    count += 1
    
    
print(count)

Submission status: Accepted

Solution code:
#-*-coding:utf-8-*-
S = input()
T = input()
sum = 0

for i in range(3):
  if S[i] == T[i]:
    sum += 1
   
print(sum)

Submission status: Accepted

Solution code:
s = input()
t = input()

ans = 0
for i in range(3):
  if s[i] == t[i]:
    ans += 1

print(ans)

Submission status: Accepted

Solution code:
s=input()
t=input()
count=0
if s[0]==t[0]:
    count+=1
if s[1]==t[1]:
    count+=1
if  s[2]==t[2]:
    count+=1
print(count)

Submission status: Accepted

Solution code:
s,t = raw_input(), raw_input()
print sum([1 if u == v else 0 for u,v in zip(s,t)])

Submission status: Accepted

Solution code:
# coding: utf-8
s = input()
t = input()
ans = 0
for i in range(3):
    if s[i] == t[i]:
        ans = ans + 1
print(ans)

Submission status: Accepted

Solution code:
def main():
  s = input()
  t = input()
  count=0
  for i in range(0,3):
    if s[i]==t[i]:
      count+=1
  print(count)
main()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
s = input()
t = input()
a = 0
for i in range(3):
    a += s[i] == t[i]
print(a)

Submission status: Accepted

Solution code:
S = input()
T = input()

count = 0
for s, t in zip(S, T):
    count += 1 if s == t else 0
print(count)

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

S = input()
T = input()

print(sum(x==y for x, y in zip(S, T)))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
sys.setrecursionlimit(10000000)
INF = 1 << 32


def solve(S: str, T: str):
    print([S[i] == T[i] for i in range(len(S))].count(True))
    return


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    S = next(tokens)  # type: str
    T = next(tokens)  # type: str
    solve(S, T)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
S = input().strip()
T = input().strip()
cnt = 0
for i in range(3):
    if S[i]==T[i]:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
S = list(input())
T = list(input())
ans = 0
for i in range(3):
  if S[i] == T[i]:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
def resolve():
  s = input()
  t = input()
  ans = 0
  for i in range(3):
    if s[i] == t[i]:
      ans += 1
  print(ans)
  return

if __name__ == "__main__":
  resolve()

Submission status: Accepted

Solution code:
S = input()
T = input()

count = 0

for i,s in enumerate(S):
    if T[i] == s:
        count += 1
print(count)