You are given a table named logs that records readings from a sensor. Each row has an id that increases by 1 with no gaps, and a num value observed at that position. A value is considered "persistent" if it appears on three or more consecutive rows (consecutive meaning consecutive id values).
Write ONE query that returns the distinct num values that appear three or more times in a row. The result should have a single column named num. Order the output by num ascending.