library

This documentation is automatically generated by online-judge-tools/verification-helper

View the Project on GitHub rainbou-kpr/library

:heavy_check_mark: test/yosupo-enumerate-quotients.test.py

Depends on

Code

# verification-helper: PROBLEM https://judge.yosupo.jp/problem/enumerate_quotients
import sys
input = sys.stdin.buffer.readline

from py.sqrt import isqrt


def main() -> None:
    n = int(input())
    v1 = []
    v2 = []
    m = isqrt(n)
    for i in range(1, m+1):
        v1.append(n//i)
        v2.append(i)
    if(v1[-1] == v2[-1]):
        v1.pop()
    v1.reverse()
    print(len(v1)+len(v2))
    print(*(v2+v1))


if __name__ == "__main__":
    main()
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.8.18/x64/lib/python3.8/site-packages/onlinejudge_verify/documentation/build.py", line 71, in _render_source_code_stat
    bundled_code = language.bundle(stat.path, basedir=basedir, options={'include_paths': [basedir]}).decode()
  File "/opt/hostedtoolcache/Python/3.8.18/x64/lib/python3.8/site-packages/onlinejudge_verify/languages/python.py", line 93, in bundle
    raise NotImplementedError
NotImplementedError
Back to top page