본문 바로가기

The Story of Joon

검색하기
The Story of Joon
프로필사진 jo_on

  • Categories (13)
    • Mathematics (1)
      • Topology (0)
      • Differential Geometry (0)
      • Complex Analysis (0)
      • Graph Theory (0)
    • Computer Science (12)
      • 알고리즘 (9)
      • 운영체제 (2)
    • 유학 이야기 (0)
Guestbook
Notice
Recent Posts
Recent Comments
Link
«   2025/05   »
일 월 화 수 목 금 토
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
Tags
  • 선형대수학
  • 정수론
  • ACM-ICPC
  • 수학
  • 선형 대수학
  • 알고리즘
  • DP
more
Archives
Today
Total
관리 메뉴
  • 글쓰기
  • 방명록
  • RSS
  • 관리

목록정수론 (1)

The Story of Joon

Linear-time construction of the sieve of Eratosthenes

에라토스테네스의 체는 소수를 구할 때 흔히 쓰는 방식이다. 구현도 쉽기 때문에 정수론과 관련된 PS 문제에서 자주 만날 수 있다. 일반적으로는 아래와 같이 구현한다. vector sieve_of_eratosthenes(int n) { vector sieve(n + 1); vector prime; for (int k = 2; k

Computer Science/알고리즘 2022. 9. 11. 15:45
Prev 1 Next

Blog is powered by kakao / Designed by Tistory

티스토리툴바