Sub Same()
Dim n, m, i As Integer, j As Integer, sStr As String, bFlag As Boolean
n = InputBox("n")
m = InputBox("m")
For i = 1 To Len(n)
For j = 1 To Len(m)
If Mid(n, i, 1) = Mid(m, j, 1) Then
bFlag = True
Exit For
End If
Next
If bFlag Then Exit For
Next
MsgBox sStr
End Sub