Pandas

Pandas (13)

Jun's N 2022. 8. 3. 20:34

How to find the positions of numbers that are multiples of 3 from a series?

# Input
ser = pd.Series(np.random.randint(1, 10, 7))
ser

# Solution
print(ser)
np.argwhere(ser % 3==0)
728x90