Suppose I have an array A = [13, 15, 17]. I want to create a new array B such that all entries apart from its 13th, 15th and 17th entries are 0, and each of these three are 1's. How can I do this?
Suppose I have an array A = [13, 15, 17]. I want to create a new array B such that all entries apart from its 13th, 15th and 17th entries are 0, and each of these three are 1's. How can I do this?