[Tutor] BEGINNER - HELP!!!
cool kid
savageapple850 at gmail.com
Mon Nov 9 10:21:10 EST 2020
Hi Leonard,
I believe this has something to do with your indentation. Try this:
>>> def rectangle_area(base,height):
area_a = base*height
print("The area is " + str(area_a))
>>> rectangle_area(5,6)
Cheers,
Cravan
On 9/11/20, 11:05 PM, "Tutor on behalf of Leonard Ujomu via Tutor" <tutor-bounces+savageapple850=gmail.com at python.org on behalf of Tutor at python.org> wrote:
Help please,
I just started learning python and I need assistance with the below code:
def rectangle_area(base,height): area_a = base*height print("The area is " + str(area_a))
rectangle_area(5,6)
I am getting the error below when I run it :Error on line 7: print("The area is " + str(area_a)) ^TabError: inconsistent use of tabs and spaces in indentation
I understand where the error is but I cannot seem to rectify it. Thank you.
Kind Regards, Leonard Ujomu
_______________________________________________
Tutor maillist - Tutor at python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
More information about the Tutor
mailing list