I have an array x :
numpy.random.seed(1)
#input
x = numpy.arange(0.,20.,1)
x = x.reshape(5,4)
print(x)
[[ 0. 1. 2. 3.]
[ 4. 5. 6. 7.]
[ 8. 9. 10. 11.]
[12. 13. 14. 15.]
[16. 17. 18. 19.]]
I want to access the maximum element in this array. In my assignment, the answer has this line to access the maximum one in x :
print(x[x==x.max()])
[19.]
I search documentation but found only one way of accessing the maximum element using argmax. I don't find the way of using "==" in the documentation, so I don't understand how this works. Can anyone explain why this works and show where it is in the documentation?