n, Q = map(int, input().split()) imos = [0] * 100001 ist = [list(map(int, input().split())) for _ in range(Q)] for i, s, t in ist: imos[s] += 1 imos[t] -= 1 for i in range(1, 100001): imos[i] += imos[i - 1] tot = [0] for i in imos: tot.append(tot[-1] + 1 / i if i else 0) ans = [0] * n for i, s, t in ist: ans[i - 1] += tot[t] - tot[s] print(*ans, sep="\n")