Skip to content
Snippets Groups Projects
Select Git revision
  • 99962c865c22836ace27f7ed41e6f61cbd55f4ff
  • master default protected
2 results

splay_tests.txt

Blame
  • prvocisla-vypis.py 224 B
    #!/usr/bin/env python3
    # Vypíše všechna prvočísla od 1 do n
    
    n = int(input())
    
    x = 2
    while x <= n:
        d = 2
        while d < x:
            if x%d == 0:
                break
            d += 1
        else:
            print(x)
    
        x += 1