def theFile(version1, version2):

	v1 = list(version1)

	v2 = list(version2)

	vnew = [elem for elem in v1 if elem in v2]
	
	#[for i in range(len(vnew)) if vnew[i] == v1]
	print ( ''.join([elem for elem in v1 if elem in v2]))
	return ''.join([elem for elem in v1 if elem in v2])


version1 = "grHenllso weortlds!"
#version1 = "CodeFigh#ts"
version2 = "H5elelo 1dworlbd!"
#version2 = "Co$deFig?hts"
theFile(version1,version2)