Gửi bài giải
Điểm:
1,00 (OI)
Giới hạn thời gian:
1.0s
Giới hạn bộ nhớ:
256M
Input:
stdin
Output:
stdout
Nguồn bài:
Dạng bài
Ngôn ngữ cho phép
C, C++, Java, Kotlin, Pascal, PyPy, Python, Scratch
A and B have known each other for many years, they often write to each other. A divide his letter into two parts and the second part starts withs some letters which are also at the end of the first parts,
The letter is very long, so B wants you to find the shortest possible result that is the content of the letter A sent.
Input
Including 2 lines:
The first line is the content of first part.
The second line is the content of the second part.
Each section consists of only latin characters and contains no spaces.
Output
The shortest possible length of the letter
Sample Input:
trunghoccosotran
trandainghia
Sample Output:
24
Bình luận