Omnimaga
General Discussion => Technology and Development => Computer Programming => Topic started by: jb3navides on May 28, 2013, 09:31:10 pm
-
if condition1 == "beef" or "lamb" or "venison", and condition2blv <= 5, and condition3 == "rare":
print condition2blv * 20
the problem seems to be the comma after "venison"
When I run it in powershell (windows) there is an arrow pointing to the comma I mentioned
condition1, condition2blv, condition3 are all variables from past functions, (involves raw_input())
-
What language is this? I may be able to help.
It looks like Python because of the raw_input(). Try deleting the commas. Python only uses commas as separators in arguments.
to fix this, it would be
if (condition1=="beef" or condition1=="lamb" or condition1=="venison") and (condition2blv <= 5) and condition3=="rare":
print condition2blv * 20
-
Yes it is python and thanks for the help, I've been spamming my powershell terminal trying to figure it out.
:banghead: :evillaugh: