Ahh - so they are literally sequential integers 1,2,3... Most people would assume you wanted a general solution for any integer (no particular sequence).
This is trivial.
In next column (B):
=if(A1<>0,1,0)
Copy this formula down - so you only have 1s and 0s in the resulting column...