Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Help With Math Problems?

Asked by
Vezious 310 Moderation Voter
8 years ago
TopTime = 25
i = 1
print (math.floor((TopTime/i+9)))

Output 34?

0
Works for me FiredDusk 1466 — 8y
0
Got it, The i+9 had to be in parenthesis Vezious 310 — 8y

1 answer

Log in to vote
0
Answered by
1waffle1 2908 Trusted Badge of Merit Moderation Voter Community Moderator
8 years ago

You have not posted a problem. You posted a script that runs and you even posted what it does. You have in no way indicated your intention for what you think the program you wrote is supposed to do or what you want it to do, you only posted a program, labeled it as a math problem and provided the answer. The answer is correct.

You are dividing by one. That is strange. Perhaps you meant to add 9 to that, in which case i+9 should be in parentheses, as per the order of operations.

Ad

Answer this question