Submission #4030694


Source Code Expand

n=int(input())
s=input()
t=input()
k=n
for i in range(n):
  if(s[i:]==t[:n-i]):
    k=i
    break
print(n+k)

Submission Info

Submission Time
Task A - Prefix and Suffix
User Motsu_xe
Language C++14 (GCC 5.4.1)
Score 0
Code Size 116 Byte
Status CE

Compile Error

./Main.cpp:1:1: error: ‘n’ does not name a type
 n=int(input())
 ^