Understanding Errors When Using abs

Asked 2 years ago, Updated 2 years ago, 18 views

When you type abs(-100+200)/2,

------------------------------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-90-41fe9b40b102>in<module>()
---->1abs(-100+200)/2

TypeError: 'int' object is not callable

he said.
I want to calculate the absolute value normally, but I can't.
I'm a beginner, so I may have overlooked something, but I can't solve it no matter how many times I try.

python

2022-09-30 12:08

1 Answers

Didn't you define a variable called abs in front of that code?
Rename the variable if you have defined it


2022-09-30 12:08

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.