Python Forum
Beginner requiring help please
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Beginner requiring help please
#3
You should check the validity of condition, like in spoken language: if this condition is met add 4 to that value.

>>> spam = 0                                                                        
>>> bacon = 'Y'                                                                     
>>> if bacon == 'Y': 
...    spam += 4 
...                                                                                
>>> spam                                                                           
4
I'm not 'in'-sane. Indeed, I am so far 'out' of sane that you appear a tiny blip on the distant coast of sanity. Bucky Katt, Get Fuzzy

Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.
Reply


Messages In This Thread
Beginner requiring help please - by w4ldom4ths - Mar-27-2020, 01:36 PM
RE: Beginner requiring help please - by deanhystad - Mar-27-2020, 02:41 PM
RE: Beginner requiring help please - by perfringo - Mar-27-2020, 02:42 PM
RE: Beginner requiring help please - by w4ldom4ths - Mar-27-2020, 04:06 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  [SOLVED] Requiring help running an old Python script (non Python savvy user) Miletkir 13 5,963 Jan-16-2021, 10:20 PM
Last Post: Miletkir

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020