In this task, you are given two strings A, B. Find the longest common substring in the strings A and B.

Ex Input:
iYuUgULgqcAgd, kRNUgULgqFv

Ex Output:
UgULgq


Ex Input:
EPUxsZtt, KgxsZuXM

Ex Output:
xsZ


Ex Input:
NLSgPe, NCSgiC

Ex Output:

Sg