asked 5.8k views
2 votes
Write the definition of a function absoluteValue, that receives an integer parameter and returns the absolute value of the parameter's value. So, if the parameter's value is 7 or 803 or 141 the function returns 7, 803 or 141 respectively. But if the parameter's value is -22 or -57, the function returns 22 or 57 (same magnitude but a positive instead of a negative). And if the parameter's value is 0, the function returns 0.

asked
User Mattmac
by
8.9k points

1 Answer

0 votes

Answer:

Explanation:

The value absolute is the function
|*|: \mathbb{R}\rightarrow \mathbb{R}^+ defined by
|x|= x if
x is a positive number and
|x|=-x if
x is a negative number.

answered
User Ishmel
by
8.5k points
Welcome to Qamnty — a place to ask, share, and grow together. Join our community and get real answers from real people.