Andrea Fontana:

I always think X < Y return a single bool,

Having a practice with NumPy and the like, I think X < Y as returning as many bools as the length of X and Y:

from numpy import *
a = array([1, 5, 1])
b = array([1, 1, 5])
a < b
array([False, False,  True], dtype=bool)


Programmers with experience of Matlab, Matcad, etc, feel the same.

Bye,
bearophile

Reply via email to