why i cant write just meter instead of "meter' in python 2.7.14? : i use python 2.7.14.....i wrote this code in python andriod Qpython3 version....but when i used it in python 2.7.14 the programme accepts strings with these " " or ' '  .......in Qpython3 i just had to to write meter....here i have to write "meter"  .....
any suggestion how to solve it?

here is the code:

    import time
    
    
    print("This is a converter.Here, you have to spell the whole name of a unit otherwise  it wont work")
    print(' ')  
    def converter():
     a=float(input("Enter a number:"    )) 
     print(" ") 
     x=input("from:"    )  
     print(" ")  
     y=input("to:"    )
     print(" ") 
     if x=="meter" and y=="kilometer" or x=="gram" and y=="kilogram":
        print(a/1000)
     elif x=="kilometer" and y=="meter" or x=="kilogram" and y=="gram":
        print(a*1000)
     #just keep adding more convertions starting with elifs inside the define function
     #and keep the else statement at the end of all elifs...
     #and that converter() function call it at the all end just once...
     #infact dont do anything escept adding elif statements....good luck 
     #dont change that float it accepts both integer and float
     else  :
                print("wrong")
                
    
     print(" ")
     print('To continue type "next",Thank you.')
     print(" ")
     print('To exit type "quit",Thank you.')
     print(" ")
     s=input()
     if s=="next":
        print(" ")
        converter()
     elif s=="quit":
        time.sleep(1)
     else:
        print("I Can't understand your command")
    converter()

