Python beginner's body fat calculator I'm very very fresh to programming. This is one of my first experiments with Python and I'm wondering in what ways I could have made this program less clunky. Specifically, is there a way that I could have used classes instead of defining my x, y, and z variables globally?

def getx():
    try:
        global x
        x = float(raw_input("Please give your weight (pounds): "))
        return x
    except ValueError:
        print("Use a number, silly!")
        getx()
def gety():
    try:
        global y
        y = float(raw_input("what is your current body fat percentage? (&gt;1): "))
        return y
    except ValueError:
        print("Use a number, silly!")
        gety()
def getz():
    try:
        global z
        z = float(raw_input("What is your desired body fat percentage? (&gt;1): "))
        return z
    except ValueError:
        print("Use a number, silly!")
        getz()
def output():
    getx()
    gety()
    getz()
    A = (x*(y/100-z/100))/(1-z/100)
    B = x - A
    print("Your necessary weight loss is %.1f pounds, and \
your final weight will be %.1f pounds" % (A,B))
    more()
def more():
    again = raw_input("Calculate again? ")
    if again.lower() == "yes" or \
       again.lower() == "y" or \
       again.lower() == "sure" or \
       again.lower() == "ok" or \
       again.lower() == "" or \
       again.lower() == "okay":
        output()
    elif again.lower() == "no" or \
         again.lower() == "n" or \
         again.lower() == "nah" or \
         again.lower() == "nope":
            end()
    else:
        more()
def end():
    print("Ok, see ya later!")
output()
all of your functions seem to do the same thing with a different message, so why not condense them and take the message as a parameter?

def get_num(msg):
    num = None
    while num is None:
        try:
            num = float(raw_input(msg))
        except ValueError:
            print("Use a number, silly!")

    return num


and then

def output():
    x = get_num('Please give your weight (pounds): ')
    y = get_num('what is your current body fat percentage? (&gt;1): ')
    z = get_num('What is your desired body fat percentage? (&gt;1): ')
    A = (x*(y/100-z/100))/(1-z/100)
    B = x - A
    print("Your necessary weight loss is %.1f pounds, and \
your final weight will be %.1f pounds" % (A,B))
    more()


in your more function you can condense your ifs with the in operator

def more():
    again = raw_input("Calculate again? ")

    if again.lower() in ["yes", "y", "sure" , "ok", "", "okay"]:
        output()
    elif again.lower() in ["no", "n", "nah", "nope"]:
        end()
    else:
        more()