On Mon, Feb 11, 2013 at 9:06 AM, Pravya Reddy wrote:
> Can you please help me with the code.
>
> #!/usr/bin/env python
> """
> inchtocm.py
>
> """
>
> def Inchtocm(inches):
> """Returns 2.54 * inches"""
> return (2.54 * float(inches_number1))
I don't know if your curriculum talks about w
On 02/11/2013 11:06 AM, Pravya Reddy wrote:
Can you please help me with the code.
#!/usr/bin/env python
"""
inchtocm.py
"""
First, remove that try/except until the code is free of obvious bugs.
It's masking where the error actually occurs. Alternatively, include a
variable there, and print
Can you please help me with the code.
#!/usr/bin/env python
"""
inchtocm.py
"""
def Inchtocm(inches):
"""Returns 2.54 * inches"""
return (2.54 * float(inches_number1))
inches = None
while True:
try:
inches_number1 = input(input("How many inches you want to convert:
"))