解题
https://blog.csdn.net/qq_25886325/article/details/118635352
select distinct c1.seat_idfrom cinema c1 join cinema c2on abs(c1.seat_id - c2.seat_id) = 1 and c1.free = 1 and c2.free = 1order by c1.seat_id;
with temp as ( select seat_id, seat_id - row_number() over() as k from cinema where free = 1)select seat_id from temp where k in ( select k from temp group by k having count(*) >= 2);
`单行代码`