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()
a=0
for i in range(3):
    if S[i]==T[i]:
        a+=1
print(a)

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 = list(input())
t = list(input())
c = 0
for i in range(3):
    if s[i] == t[i]:
        c += 1
print(c)

Submission status: Accepted

Solution code:
S=list(map(str,input()))
T=list(map(str,input()))
count=0

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

Submission status: Accepted

Solution code:
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


# 初項s, 交差dのn個の数列の和
def sum_of_arithmetic_progression(s, d, n):
    return n * (2 * s + (n - 1) * d) // 2


# aとbの最大公約数
def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)


# aとbの最小公倍数
def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


def main():
    S = input()
    T = input()
    ans = 0
    for i in range(3):
        ans += S[i] == T[i]
    print(ans)

if __name__ == '__main__':
    main()

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

A = sys.stdin.readline()
B = sys.stdin.readline()
ans = 0

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

Submission status: Accepted

Solution code:
import math
import sys
input = sys.stdin.readline


def main():
    sc = Scan()
    s = sc.strarr()[0]
    t = sc.strarr()[0]
    count = 0
    for ss, tt in zip(s, t):
        if ss == tt:
            count += 1
    print(count)


class Scan():

    def intarr(self):
        line = input()
        array = line.split(' ')
        num_array = [int(n) for n in array]
        return num_array

    def strarr(self):
        line = input()
        array = line.split(' ')
        array[-1] = array[-1].strip('\n')
        return array


main()

Submission status: Accepted

Solution code:
from collections import defaultdict,deque
import sys,heapq,bisect,math,itertools,string,queue,copy,time
import numpy as np
sys.setrecursionlimit(10**8)
INF = float('inf')
mod = 10**9+7
eps = 10**-7
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))
def inpl_str(): return list(sys.stdin.readline().split())


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()

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

Submission status: Accepted

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

res=0
for s,t in zip(S,T):
  res+=int(s==t)
print(res)

Submission status: Accepted

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

Submission status: Accepted

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

tenki = 0

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

print(tenki)

Submission status: Accepted

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

count = 0
for s, t in zip(s, t):
  if s == t:
    count += 1

print(count)

Submission status: Accepted

Solution code:
import sys
import math
import bisect
from collections import defaultdict, deque, Counter
from heapq import heappush, heappop


def LI(): return [int(x) for x in sys.stdin.readline().split()]


def I(): return int(sys.stdin.readline())


def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res


def IR(n):
    return [I() for i in range(n)]


# A
def A():
    s = S()
    t = S()
    ans = 0
    for i in range(3):
        if s[i] == t[i]:
            ans += 1
    print(ans)
    return


# B
def B():
    return


# C
def C():
    return


# D
def D():
    return


# E
def E():
    return


# F
def F():
    return


# Unittest
def resolve():
    A()
    return


# Solve
if __name__ == "__main__":
    A()

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() for i in range(2)]
cnt = 0
for i in range(3):
    if s[0][i] == s[1][i]:
        cnt = cnt + 1
print(cnt)

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+=1

print(ans)

Submission status: Accepted

Solution code:
s1 = input()
s2 = input()
cnt = 0

for ss1, ss2 in zip(s1, s2):
    if ss1 == ss2:
        cnt += 1

print(cnt)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = list(str(input()))
t = list(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()

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:
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=list(str(input()))
T=list(str(input()))
ans=0
for i in range(3):
    if S[i:i+1]==T[i:i+1]:
        ans+=1
    else:
        pass
print(ans)

Submission status: Accepted

Solution code:
ls_s = [s for s in input()]
ls_t = [t for t in input()]

cnt = 0

for i in range(3):
    if ls_s[i] == ls_t[i]:
        cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
S = input()
T = input()
sum = 0
for i in range(3):
    if S[i] == T[i]:
      sum = sum + 1
    else:
      sum = sum + 0
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:
import sys
input = sys.stdin.readline
def print_ans(S, T):
    """Test Case
    >>> print_ans("CSS", "CSR")
    2
    >>> print_ans("SSR","SSR")
    3
    """
    ans = 0
    for i in range(len(S)):
        if S[i] == T[i]:
            ans += 1
    print(ans)


if __name__ == '__main__':
    S = input().rstrip()
    T = input().rstrip()
    print_ans(S, T)

Submission status: Accepted

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

if s[0] == t[0]: c+=1
if s[1] == t[1]: c+=1
if s[2] == t[2]: c+=1

print (c)

Submission status: Accepted

Solution code:
S=input()
T=input()
lst=[]
for i in range(0,3):
    if S[i]==T[i]:
        lst.append('7')
print(len(lst))

Submission status: Accepted

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

Submission status: Accepted

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

S_list = list(S)
T_list = list(T)

i = 0
x = 0

while(i < 3):
    if(S_list[i] == T_list[i]):
        x = x + 1
    i = i + 1

print(x)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = str(input())
T = str(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())
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()
ans = 0

for x in range(3):
    if s[x] == t[x] :
        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:
S = input()
T = input()

ans = 0
if S[0] == T[0]:
    ans += 1
if S[1] == T[1]:
    ans += 1
if S[2] == T[2]:
    ans += 1

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# ABC 139: A – Tenki
s = input()
t = input()

num_correct = 0

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

print(num_correct)

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()

res = sum([s[i] == t[i] for i in range(3)])
print(res)

Submission status: Accepted

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

Submission status: Accepted

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

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_list = list(input())

T_list = list(input())

l = 0
for i in range(3):
  if S_list[i] == T_list[i]:
    l = l + 1

print(l)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# https://atcoder.jp/contests/abc139/tasks/abc139_a
S = input()
T = input()

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

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

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

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 = [s == t for (s, t) in zip(S, T)]
print(sum(ans))

Submission status: Accepted

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

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

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 = 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()
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()

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

print (result)

Submission status: Accepted

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

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

print(result)

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()

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 = count + 1
print(count)

Submission status: Accepted

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

k = 0

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

Submission status: Accepted

Solution code:
print(sum([1 if i==e else 0 for i,e in zip(input(),input())]))

Submission status: Accepted

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

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()
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:
ans = 0
a = input()
b = input()
for i in range(3):
  if a[i] == b[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:
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()
count = 0

for i, v in zip(s,t):
  if i == v:
    count += 1
    
print(count)

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(3):
    if s[i] == t[i]:
        cnt += 1
    else:
        continue
print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s, t = input(), input()
print(sum([s[i] == t[i] for i in range(3)]))

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

s = input();
t = input();

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

print(count_all);
# TODO: write code...

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
i = 0
chara1 = input()
chara1_list = list(chara1)
chara2 = input()
chara2_list = list(chara2)
if chara1_list[0] == chara2_list[0]:
    i += 1
if chara1_list[1] == chara2_list[1]:
    i += 1
if chara1_list[2] == chara2_list[2]:
    i += 1
print(i)

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()
count = 0

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

print(count)

Submission status: Accepted

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

n = [sx == tx for sx, tx in zip(s, t)]
print(n.count(True))

Submission status: Accepted

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

Submission status: Accepted

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

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

print(answer)

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()


def solve(S, T):
    cnt = 0
    for i in range(0, 3):
        if S[i] == T[i]:
            cnt += 1

    return cnt


print(solve(S, T))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=list(input())
t=list(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
print(sum(u==v for u,v in zip(S(),S())))

Submission status: Accepted

Solution code:
S=input()
T=input()
print(sum([1 for u,v in zip(S,T) if u==v]))

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:
import sys


def solve():
    input = sys.stdin.readline
    s = str(input().rstrip('\n'))
    t = str(input().rstrip('\n'))
    cnt = 0
    for i in range(len(s)):
        if s[i] == t[i]:
            cnt += 1
    print(cnt)


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
s1 = input()
s2 = input()
c = 0
for x, y in zip(s1, s2):
	if x == y:
		c += 1
print(c)

Submission status: Accepted

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

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()
 
 
cnt = 0
for i in range(3):
    if s[i] == t[i]:
        cnt += 1
 
print(cnt)

Submission status: Accepted

Solution code:
count = 0
for s in zip(input(), input()):
  if s[0] == s[1]:
    count += 1
      
print(count)

Submission status: Accepted

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

print(sum(int(a==b) for a,b in zip(S,T)))

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()

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

    
print(count)

Submission status: Accepted

Solution code:
forecasts     = input()
real_weathers = input()

correct_number = 0
for date in range(len(forecasts)):
    if forecasts[date] == real_weathers[date]:
        correct_number += 1
print(correct_number)

Submission status: Accepted

Solution code:
x = input()
y = input()

cnt = 0

for i,l in zip(x,y):
  if i == l:
    cnt += 1
    
print(cnt)

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=list(input())
T=list(input())
ans=0
for n in range(3):
    if S[n]==T[n]:
        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 = input()
t = input()

answer = 0

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

print(answer)

Submission status: Accepted

Solution code:
#139
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())
answer = 0

#print(S)
#print(T)
#rangeが扱えるのは整数
for i in range(3):
    if S[i] == T[i] :
        answer += 1
print(answer)

Submission status: Accepted

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

for pre, acc in zip(s, t):
    if pre == acc:
        count += 1
print(count)

Submission status: Accepted

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

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

print(res)

Submission status: Accepted

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


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

Submission status: Accepted

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

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

print(n)

Submission status: Accepted

Solution code:
forecast = input()
real = input()
ans = 0

for i in range(3):
    if forecast[i] == real[i]:
        ans = ans + 1

print(ans)

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:
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:
from sys import stdin
S = input()
T = input()
correct = 0
for i in range(3):
  if S[i] == T[i]:
    correct += 1
print(correct)

Submission status: Accepted

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

Submission status: Accepted

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

L=[]
i = 0
while  i <= 2:
    if S[i]==T[i]:
        L.extend([i])
    i += 1

print(len(L))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = str(input())
t = str(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()
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 T[i] == S[i]:
        ans +=1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

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 = str(input())
T = str(input())
result = 0
if S[0] == T[0]:
    result += 1
if S[1] == T[1]:
    result += 1
if S[2] == T[2]:
    result += 1
print(result)

Submission status: Accepted

Solution code:
a,b = input(),input()
ans = 0
if a[0] == b[0]:
  ans += 1
if a[1] == b[1]:
  ans += 1
if a[2] == b[2]:
  ans += 1
print(ans)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 18,Oct,2019
"""

import sys
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 7)

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


print(ans)

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 permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy,copy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd

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()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

def main():
    s = input()
    t = input()
    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:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits

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()))
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 = input()
T = input()
N = sum(1 if s == t else 0 for s, t in zip(S,T))
print(str(N))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def t(a, b):
    return [i == j for i, j in zip(a, b)].count(True)


if __name__ == '__main__':
    print(t(input(), input()))

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()

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

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

Solution code:
yohou=input()
tenki=input()
yohou1=yohou[0]
yohou2=yohou[1]
yohou3=yohou[2]
tenki1=tenki[0]
tenki2=tenki[1]
tenki3=tenki[2]
kekka=[yohou1==tenki1, yohou2==tenki2, yohou3==tenki3]
a=kekka.count(True)
print(a)

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:
A = input()
B = input()
x = 0
for i in range(3):
  if A[i] == B[i]:
    x += 1
print(x)

Submission status: Accepted

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

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=str(input())
t=str(input())
res=0
for i in range(3):
  if(s[i]==t[i]):
    res+=1
print(res)

Submission status: Accepted

Solution code:
import sys

T = input()
S = input()

n = 0

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

print(n)

Submission status: Accepted

Solution code:
a = str(input())#入力S
b = str(input())#入力T
#print(a[n])
#print(b[n])
x=0
for n in range(3):
  if a[n] == b[n]:
    x+=1
print(x)

Submission status: Accepted

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

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

print(answer)

Submission status: Accepted

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

Submission status: Accepted

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

p=0
for i in range(0,3):
    if S[i]==T[i]:
        p=p+1
    else:
        continue
print(p)

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

T=input()
S=input()

n = 0

if T[0] == S[0]:
  	n = 1
if T[1] == S[1]:
  	n += 1
if T[2] == S[2]:
  	n += 1

print(n)

Submission status: Accepted

Solution code:
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

S = readline().rstrip().decode('utf-8')
T = readline().rstrip().decode('utf-8')

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

Submission status: Accepted

Solution code:
forecast = input()
actual = input()

point = 0
for s, t in zip(forecast, actual):
	if s==t:
		point += 1
print(point)

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())
    count = 0

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
S = list(map(str,input()))
T = list(map(str,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() )

count = 0

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

Submission status: Accepted

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

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

print(res)

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()

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())

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

print(counter)

Submission status: Accepted

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

count = 0
#iを３回数えてもらう
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())
count = 0
for i in range(0,3):
    if s[i] == t[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:
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=str(input())
t=str(input())
c=0
for i in range(len(s)):
  if s[i]==t[i]:
    c += 1
print(c)

Submission status: Accepted

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

Submission status: Accepted

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