Ban exec for fizzbuzz2
This commit is contained in:
parent
ef0de7f17f
commit
b2484cb97b
1 changed files with 7 additions and 7 deletions
|
@ -1,8 +1,8 @@
|
|||
import sys
|
||||
|
||||
code = sys.stdin.read()
|
||||
|
||||
if ("i" in code) or ("I" in code) or ("?" in code):
|
||||
print "Your program contains an 'i', 'I', or '?'. Please remove it and try again."
|
||||
else:
|
||||
import sys
|
||||
|
||||
code = sys.stdin.read()
|
||||
|
||||
if ("i" in code) or ("I" in code) or ("?" in code) or ("eval" in code) or ("exec" in code):
|
||||
print "Your program contains an 'i', 'I', or '?'. Please remove it and try again."
|
||||
else:
|
||||
print "OK"
|
||||
|
|
Loading…
Reference in a new issue