New submission from Matthew Brunt <mbrun...@gmail.com>:

i'm very new to python (currently going through a python for beginners book at 
work to pass the time), and i'm having trouble with an if statement exercise.  
basically, i'm creating a very simple password program that displays "Access 
Granted" if the if statement is true.  the problem i'm having is that no matter 
what i set the password to, it seems like it's ignoring the if statement.  the 
code is copied below, and i greatly appreciate any input.

# Granted or Denied
# Demonstrates an else clause

print("Welcome to System Security Inc.")
print("-- where security is our middle name\n")

password = input("Enter your password: ")

if password == "a":
    print("Access Granted")

input("\n\nPress the enter key to exit.")

----------
components: IDLE
messages: 137883
nosy: Matthew.Brunt
priority: normal
severity: normal
status: open
title: If statement
type: performance
versions: Python 3.2

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue12280>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to