#π Why does it have issues with negative numbers ?
30 messages Β· Page 1 of 1 (latest)
@real ridge
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
!e print(5 ** -1)
@wispy agate :white_check_mark: Your 3.12 eval job has completed with return code 0.
0.2
I dont think so
Oh I see
they probably do not count the - as part of the length
5 ** -1 is just (1/5) ** 1
in standard notation, when u have a negative power it means it goes down to the denominator (or numerator if its in the denominator)
I see my bad just trying to help
!e py def multifply(n): return n*(5**len(str(n))) print(multifply(-9))
@radiant wave :white_check_mark: Your 3.12 eval job has completed with return code 0.
-225
sorry got some good
let me read this
Yeah minus is counted as a character
ohhhh
im a silly billy
xd
thanks ahha
!close
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.