Python Programming - Arrays - Discussion
Discussion Forum : Arrays - General Questions (Q.No. 36)
36.
How do you check if all elements in a NumPy array
arr
are non-zero?
Answer: Option
Explanation:
The code
np.all(arr != 0)
checks if all elements in the array are non-zero.
Discussion:
Be the first person to comment on this question !
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers