checking elements on either side of current element in list

后端 未结 0 841
半阙折子戏
半阙折子戏 2021-01-13 06:46

I have an array:

array1 = [0, 0, 0, 1, 1, 2, 1, 2, 2, 1]

I\'d like to iterate through the elements and if there is a 2 that is not next to an

相关标签:
回答
  • 消灭零回复
提交回复
热议问题