Showing posts with label feet to centimeter converter in python. Show all posts
Showing posts with label feet to centimeter converter in python. Show all posts

Thursday, March 17, 2016

Feet To Centimeter Converter in Python

A simple program that will ask the user to give a value in feet and then it will convert it in centimeters equivalent using Python as our programming language.

If you have some questions please send me an email at jakerpomperada@gmail.com and jakerpomperada@yahoo.com.

My mobile number here in the Philippines is 09173084360.




Sample Program Output


Program Listing

print("");
print("Feet To Centimeter Converter");
print("");
feet = input("How many feet(s) : ")
value = float(feet)

def find_centimeters(value):   
    return float(value)* 30.48


print("");

get_result = find_centimeters(value)
final_result = int((get_result * 100) + 0.5) /100.0

print("The equivalent value of ", value, " feet(s) in centimeters is "
      ,final_result,' centimeter(s).')
print("");
print("End of Program")
print("");