Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
配列が与えられた場合、その前の数字と後の数字が等しい合計になるインデックスを見つけたいと思います。
たとえば、次のような配列 [4,5,6,11,7,8]
[4,5,6,11,7,8]
出力はインデックス3なので4+5+6 = 7+8
3
4+5+6 = 7+8