We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Python
- Numpy
- Floor, Ceil and Rint
- Discussions
Floor, Ceil and Rint
Floor, Ceil and Rint
Sort by
recency
|
276 Discussions
|
Please Login in order to post a comment
code is
import numpy
numpy.set_printoptions(legacy='1.13')
my_arr = list(map(float, input().split()))
print(numpy.floor(my_arr)) print(numpy.ceil(my_arr)) print(numpy.rint(my_arr))
import numpy numpy.set_printoptions(legacy='1.13') A = numpy.array(list(map(float, input().strip().split()))) print(numpy.floor(A)) print(numpy.ceil(A)) print(numpy.rint(A))