>576

numpyは使ったことないから、リファレンス見ながら適当に書いた。
a==b==cだとエラーになるので、a==bとb==cをlogical_andでつないだら動いた。

print(np.sum(np.logical_and(a == b, b == c)))