File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -308,6 +308,19 @@ freeing us from having to manually examine every plot for features we've seen be
308308> Compare your implementation with your partner's:
309309> do you get the same answer for all possible pairs of numbers?
310310>
311+ > > ## Hint
312+ > > There is a [built-in function `abs`][abs-function] that returns the absolute value of
313+ > > a number:
314+ > > ~~~
315+ > > print(abs(-12))
316+ > > ~~~
317+ > > {: .language-python}
318+ > > ~~~
319+ > > 12
320+ > > ~~~
321+ > > {: .output}
322+ > {: .solution}
323+ >
311324> > ## Solution 1
312325> > ~~~
313326> > a = 5
@@ -477,4 +490,6 @@ freeing us from having to manually examine every plot for features we've seen be
477490> {: .solution}
478491{: .challenge}
479492
493+ [abs-function]: https://docs.python.org/3/library/functions.html#abs
494+
480495{% include links.md %}
You can’t perform that action at this time.
0 commit comments