Soooo... I have this pattern... 110011001100...
in
Programming Questions
•
2 years ago
I have this pattern:
11001100110011001100…
I’d like to write a function which returns 1 or 0 based on the position in this list. That is, an input of 0 returns 1. An input of 1 returns 1. An input of 2 returns 0. An input of 3 returns 0, etc.
Can anyone provide a clever way to code this?
Thanks!
1