#A little more complex in terms of params:

def SwapCaseAndCenter(*kwargs):

        if upper_or_lower == "upper":
                print a_string.center(center_num).upper()

        if upper_or_lower == "lower":
                print a_string.center(center_num).lower()

a_string = raw_input("Give me a word, or letter: ")
upper_or_lower = raw_input("upper, or lower character(s): ")
center_num = int(raw_input("Where should number be centered?: "))
SwapCaseAndCenter(a_string, upper_or_lower, center_num)



-- 
Best Regards,
David Hutto
CEO: http://www.hitwebdevelopment.com
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to