local a = io.read("*l")
local b = io.read("*l")
function test(a,b)
    local test = string.format("[%s]",a)
    local test2 = string.format("[%s]",b)
    local x = string.gsub(a,test2,"")
    local y = string.gsub(b,test,"")
    local newTest1 = {}
    local newTest2 = {}
    local num1 = 0
    local num2 = 0
    for i=1,string.len(x) do
        if not newTest1[string.sub(x,i,i)] then
            num1 = num1 + 1
            newTest1[string.sub(x,i,i)] = true
        end
    end

    for i=1,string.len(y) do
        if newTest2[string.sub(y,i,i)] then

        else
            num2 = num2 + 1
            newTest2[string.sub(y,i,i)] = true
        end

    end
    if math.abs(num1)%2 == 0 then
        print("Yes")
    else
        print("No")
    end

end
test(a,b)

