#-*- coding: UTF-8 -*-
class Solution(object):
def canConstruct(self, ransomNote, magazine):
ransomNote=list(ransomNote)
magezine=list(magazine)
for ransom in ransomNote:
if(magezine.__contains__(ransom)):
point=magezine.index(ransom)
del magezine[point]
else:
return False
return True
sol=Solution()
print sol.canConstruct('aa', 'aab')