Python function problem
Can someone please explain to me why this is not working.
u = input("Please enter your name: ")
Please enter your name: Kieran
Name Error: Name 'u' is not defined.
How do i go about defining a variable whilst creating a function?
ps I am new to python and coding in general as im sure you can tell.
Ahh I see now, the variable is local. Is there anyway I can use these variables outside of the function itself?
|All times are GMT +1. The time now is 08:09 PM.|
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.