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.
この形式のリストのサブシーケンスを取得するコードを作成しようとしています:
l = [240,200,160,4,0,0,0,0,4,4,4,0,0,0,1,1,1,1]
基本的に、ゼロではないサブシーケンスを取得する必要があるため、次の形式の出力が必要です。
output = [[255,200,160,4] , [4,4,4] , [1,1,1,1]]
ありがとうございました。