I have a very large list of positions (DNA loci) and need to convert it a sequence of binaries.
Example:
Input:
[3,5] # positions 3 and 5
Output:
[0,0,1,0,1] # 1s only for third and fifth positions
The size of the input list is in the order of millions and the max position is 2.3 billion (the size of the DNA).