Arrays numpy hackerRank solution
import numpy
def arrays(arr):
string_array = numpy.array(arr,float)
return(numpy.flipud(string_array))
arr = input().strip().split(' ')
result = arrays(arr)
print(result)
Sample input :
1 2 3 4 -8 -10Sample Output:[-10. -8. 4. 3. 2. 1.]
Comments
Post a Comment