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:
import sys, bisect, math, itertools, string, queue, copy
# import numpy as np
# import scipy
# from collections import Counter,defaultdict,deque
# from itertools import permutations, combinations
# from heapq import heappop, heappush
# # input = sys.stdin.readline
# sys.setrecursionlimit(10**8)
mod = 10**9+7
def inp(): return int(input())
def inpm(): return map(int,input().split())
def inpl(): return list(map(int, input().split()))
def inpls(): return list(input().split())
def inplm(n): return list(int(input()) for _ in range(n))
def inplL(n): return [list(input()) for _ in range(n)]
def inplT(n): return [tuple(input()) for _ in range(n)]
def inpll(n): return [list(map(int, input().split())) for _ in range(n)]
def inplls(n): return sorted([list(map(int, input().split())) for _ in range(n)])

al = input()
bl = input()
ans = 0
for i in range(0, 3):
    if(al[i] == bl[i]):
        ans += 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
 
## Library
 
import sys
from fractions import gcd
import math
from math import ceil,floor
import collections
from collections import Counter
import itertools
import copy

## input
 
# N=int(input())
# A,B,C,D=map(int, input().split())
# S = input()
# yoko = list(map(int, input().split()))
# tate = [int(input()) for _ in range(N)]
# N, M = map(int,input().split()) 
#    P = [list(map(int,input().split())) for i in range(M)]
#    S = []
#    for _ in range(N):
#        S.append(list(input()))

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:
import sys
import heapq
import math
import fractions
import bisect
import itertools
from collections import Counter
from collections import deque
from operator import itemgetter
def input(): return sys.stdin.readline().strip()
def mp(): return map(int,input().split())
def lmp(): return list(map(int,input().split()))

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

cnt = 0
for s, t in zip(S, T):
    cnt += s==t
    
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 = 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 i, j in zip(s, t):
    if i == j:
        ans+=1
print(ans)

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

S = stdin.readline().rstrip()
T = stdin.readline().rstrip()

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

print(ans)

Submission status: Accepted

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


if __name__ == "__main__":
    main()

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

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

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(len(S)):
    if S[i] == T[i]:
        ans += 1 
print(ans)

Submission status: Accepted

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

a = 0

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

print(a)

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

Submission status: Accepted

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

result = len(list([True for c1, c2 in zip(s, t) if c1 == c2]))
print(result)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
t = input()
print(len([a == b for a, b in zip(s, t) if a == b]))

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)

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

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

print(cnt)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=str(input())
s1=str(input())
e=0
for i in range(0,len(s)):
    if(s[i]==s1[i]):
        e=e+1
print(e)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#n=int(input())
#a==map(int, input().split())
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 i in range(3):
    if S[i]==T[i]:
        count=count+1
    else:
        pass
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:
print(3-sum(i!=j for i,j in zip(*open(0))))

Submission status: Accepted

Solution code:
print(3-sum(i!=j for i,j in zip(*open(0))))

Submission status: Accepted

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

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:
#k = int(input())
#s = input()
#a, b = map(int, input().split())
#s, t = map(str, input().split())
#l = list(map(int, input().split()))

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

Submission status: Accepted

Solution code:
import re
import sys
import math
import itertools
import bisect
from copy import copy
from collections import deque,Counter
from decimal import Decimal
import functools
def v(): return input()
def k(): return int(input())
def S(): return input().split()
def I(): return map(int,input().split())
def X(): return list(input())
def L(): return list(input().split())
def l(): return list(map(int,input().split()))
def lcm(a,b): return a*b//math.gcd(a,b)
sys.setrecursionlimit(10 ** 9)
mod = 10**9+7
cnt = 0
ans = 0
inf = float("inf")

a = X()
b = X()
for i in range(len(a)):
    if a[i]==b[i]:
        cnt+=1

print(cnt)

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:
# -*- coding: utf-8 -*-

def main():

    S = input()
    T = input()

    n = len(S)

    ans = 0

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

    print(ans)


if __name__ == "__main__":
    main()

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
loop = 0
for i in S:
  if i == T[loop]:
    cnt += 1
  loop += 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:
import heapq
t = 1
def max(a,b):
	if a > b:
		return a
	return b
def min(a,b):
	if a < b:
		return a
	return b

while t > 0:
	t -= 1
	# n,k = map(int,input().split())
	# n = int(input())
	s = input()
	r = input()
	ans = 0
	for i in range(0,len(s)):
		if(s[i] == r[i]):
			ans += 1
	print(ans)
	# v = list(map(int,input().strip().split()))[0:n]
	# b = list(map(int,input().strip().split()))[0:n]
	# c = list(map(int,input().strip().split()))[0:n-1]
	# s = input()
	# for i in range(n,0,-1):

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()
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()
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(3):
    if S[i] == T[i]:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
print(sum([i==j for i,j in zip(input(),input())]))

Submission status: Accepted

Solution code:
print(len([1 for i,j in zip(input(),input()) if i==j]))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# abc139_a.py
# https://atcoder.jp/contests/abc139/tasks/abc139_a

# A - Tenki /
# 実行時間制限: 2 sec / メモリ制限: 1024 MB
# 配点 : 100点

# 問題文
# ある 3日間の天気予報が、長さ 3 の文字列 Sとして与えられます。
# Sの i (1≤i≤3) 文字目が S のとき、i日目の天気予報が晴れだったことを、C のときは曇りだったことを、R のときは雨だったことを意味します。
# また 3日間の実際の天気が、長さ 3 の文字列 Tとして与えられます。
# Tの i (1≤i≤3) 文字目が S のとき、i日目の実際の天気が晴れだったことを、C のときは曇りだったことを、R のときは雨だったことを意味します。
# 3日間で天気予報が的中した日が何日あるかを出力してください。

# 制約
#     Sおよび T は長さ 3の文字列である。
#     Sおよび Tは S, C, R のみからなる。

# 入力
# 入力は以下の形式で標準入力から与えられる。
# S
# T

# 出力
# 3日間で天気予報が的中した日が何日あるかを出力せよ。

# 入力例 1
# CSS
# CSR

# 出力例 1
# 2

#     1日目の天気予報は曇り、実際の天気は曇りなので、この日の天気予報は的中している。
#     2日目の天気予報は晴れ、実際の天気は晴れなので、この日の天気予報は的中している。
#     3日目の天気予報は晴れ、実際の天気は雨なので、この日の天気予報は的中していない。

# 以上より、このケースでは 3日間で天気予報が的中した日が 2日あります。

# 入力例 2
# SSR
# SSR

# 出力例 2
# 3

# 入力例 3
# RRR
# SSS

# 出力例 3
# 0


global FLAG_LOG
FLAG_LOG = False


def log(value):
    # FLAG_LOG = True
    # FLAG_LOG = False
    if FLAG_LOG:
        print(str(value))


def calculation(lines):
    S = lines[0]
    T = lines[1]
    # N = int(lines[0])
    # X, A = list(map(int, lines[0].split()))
    # values = list(map(int, lines[1].split()))
    # values = list(map(int, lines[2].split()))
    # values = list()
    # for i in range(6):
    #     values.append(int(lines[i]))
    # valueses = list()
    # for i in range(M):
    #     valueses.append(list(map(int, lines[i+1].split())))

    result = 0

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

    return [result]


# 引数を取得
def get_input_lines(lines_count):
    lines = list()
    for _ in range(lines_count):
        lines.append(input())
    return lines


# テストデータ
def get_testdata(pattern):
    if pattern == 1:
        lines_input = ['CSS', 'CSR']
        lines_export = [2]
    if pattern == 2:
        lines_input = ['SSR', 'SSR']
        lines_export = [3]
    if pattern == 3:
        lines_input = ['RRR', 'SSS']
        lines_export = [0]
    return lines_input, lines_export


# 動作モード判別
def get_mode():
    import sys
    args = sys.argv
    global FLAG_LOG
    if len(args) == 1:
        mode = 0
        FLAG_LOG = False
    else:
        mode = int(args[1])
        FLAG_LOG = True
    return mode


# 主処理
def main():
    import time
    started = time.time()
    mode = get_mode()
    if mode == 0:
        lines_input = get_input_lines(2)
    else:
        lines_input, lines_export = get_testdata(mode)

    lines_result = calculation(lines_input)

    for line_result in lines_result:
        print(line_result)

    # if mode > 0:
    #     print(f'lines_input=[{lines_input}]')
    #     print(f'lines_export=[{lines_export}]')
    #     print(f'lines_result=[{lines_result}]')
    #     if lines_result == lines_export:
    #         print('OK')
    #     else:
    #         print('NG')
    # finished = time.time()
    # duration = finished - started
    # print(f'duration=[{duration}]')


# 起動処理
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:
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(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()
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()
p = 0
for i in range(3):
  if S[i] == T[i]:
    p+=1
print(p)

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

Submission status: Accepted

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

Submission status: Accepted

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

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(map(str,input()))
t = list(map(str,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()
count=0
for i in range(len(S)):
  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(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 str(s[i]) ==  str(t[i]):
        cnt += 1

print(cnt)

Submission status: Accepted

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

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

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:
import sys
S = input()
T = input()

if not ( len(S) == 3 and len(T) == 3 ): sys.exit()
if not ( ('S' in S or 'C' in S or 'R' in S) and ('S' in T or 'C' in T or 'R' in T)):
    sys.exit()

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

print(count)

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(len(S)):
  if S[i] == T[i]:
    count += 1
print(count)

Submission status: Accepted

Solution code:
import sys
from collections import deque


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


def main():
    S =input()
    T =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 = 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()
ans = 0
for i in range(3):
    ans += S[i] == T[i]

print(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=str(input())
T=str(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()
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:
forecast = input()
actual = input()
correct = 0

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

Submission status: Accepted

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

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

print(x)

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 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 a, b in zip(s, t):
    if a == b:
        cnt += 1
print(cnt)

Submission status: Accepted

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

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:
s = input()
t = input()
print(sum(s[i] == t[i] for i in range(3)))

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

 print(ans)
main()

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()
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(0,3):
    if S[i] == T[i]:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
def main() -> None:
    S = input()
    T = input()
    print(sum(s == t for s, t in zip(S, T)))


if __name__ == '__main__':
    main()

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:
#!/usr/bin/env python
import sys
import re
from collections import deque, defaultdict
from itertools import combinations, combinations_with_replacement
import bisect
from math import factorial, sqrt, log, ceil, floor
sys.setrecursionlimit(1000000)


def main():
    input = sys.stdin.readline
    #N, M = map(int, input().split())
    #N, K = map(int, input().split())
    #ps = list(map(int, input().split()))
    
    S = input().strip()
    T = input().strip()

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


if __name__ == '__main__':
    main()

Submission status: Accepted

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

c=0

for i in range(3):
  if S[i] ==T[i]:
    c+=1
  else:
    pass
  i+=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:
a, b= [input() for i in range(2)]
ans = 0;
for i in range(3):
    if a[i]==b[i]:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
s = list(input())
t = list(input())
a = zip(s, t)

b = list(map(lambda xy: xy[0] == xy[1], a))
print(b.count(True))

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

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

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

Submission status: Accepted

Solution code:
def resolve():
    S = list(input())
    T = list(input())
    cnt = 0
    for i in range(3):
        if S[i] == T[i]:
            cnt += 1
    print(cnt)
    
if '__main__' == __name__:
    resolve()

Submission status: Accepted

Solution code:
S,T=[input() for i in range(2)]
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:
a = input()
b = 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:
s = list(input())
t = list(input())
c = 0
count = 0
for i in range(3):
    if s[c] == t[c]:
        count += 1
        c += 1
    else:
        c += 1
print(count)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
s = input()
t = input()
r=0
for i in range(0,3):
  if s[i]==t[i]:
    r=r+1
print(r)

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

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:
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()
s_l = list(s)
t_l = list(t)
count = 0

for i in range(len(s)):
  if s_l[i] == t_l[i]:
    count += 1
  else:
    continue
print(count)

Submission status: Accepted

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

while i < 3:
  if s[i] == t[i]:
    count += 1
  i += 1
print(count)

Submission status: Accepted

Solution code:
A = input()
B = input()
ans = 0
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(3):
  if s[i] == t[i]:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
#<ABC.139>
#<A>
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:
a = input()
b = input()
ans = 0
for i in range(3):
    if a[i] == b[i]:
        ans+=1
print(ans)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

print(c)

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()
o=0
for (i,j) in zip(s,t):
  if i==j:
    o+=1
print(o)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# from collections import Counter
# n = int(input())
# li = list(map(int, input().split()))
# a, b = map(int, input().split())
# a = int(input())
s = input()
r = input()
print(sum(1 if s[i] == r[i] else 0 for i in range(len(s))))

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

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

Submission status: Accepted

Solution code:
ss = input()
tt = input()

print(sum([s==t for s, t in zip(ss,tt)]))

Submission status: Accepted

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

c = 0

for i in range(3):

    if S[i]==T[i]:
        c += 1

    i += 1

print(c)

Submission status: Accepted

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

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

count = 0
for i in range(0, 3, 1):
  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() #実際の天気
count = 0

# for 文　▶︎　繰り返し文のこと！
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

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

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)