Pastebin
API
tools
faq
paste
Login
Sign up
SHARE
TWEET
normalize.py
gauravssnl
Apr 28th, 2017
77
0
Never
Add comment
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!
Python
0.13 KB
| None
|
0
0
raw
download
clone
embed
print
report
def
normalize
(
a
)
:
a
=
[
(
x-
min
(
a
)
)
/
(
max
(
a
)
-
min
(
a
)
)
for
x
in
a
]
return
a
print
(
normalize
(
[
10.5
,
30.9
,
20.5
,
26.5
,
40.0
]
)
)
Advertisement
Add Comment
Please,
Sign In
to add comment
Public Pastes
Untitled
2 min ago | 12.05 KB
Untitled
1 hour ago | 25.85 KB
Untitled
2 hours ago | 5.49 KB
Untitled
2 hours ago | 1.60 KB
Untitled
2 hours ago | 1.50 KB
Untitled
3 hours ago | 0.08 KB
Untitled
3 hours ago | 14.53 KB
Untitled
3 hours ago | 6.09 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the
Cookies Policy
.
OK, I Understand
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!