leetcode

Solution to some Leetcode problems written in C++
git clone git://git.dimitrijedobrota.com/leetcode.git
Log | Files | Refs | README | LICENSE

0180.sql (175B)


      1 SELECT DISTINCT L1.num AS ConsecutiveNums
      2 FROM Logs L1
      3 LEFT JOIN Logs L2 ON L1.id + 1 = L2.id
      4 LEFT JOIN Logs L3 ON L1.id + 2 = L3.id
      5 WHERE L1.num = L2.num AND L2.num = L3.num