#P1579. 哥德巴赫猜想(升级版)

    ID: 567 远端评测题 1000ms 125MiB 尝试: 1 已通过: 1 难度: 3 上传者: 标签>数学枚举,暴力素数判断,质数,筛法

哥德巴赫猜想(升级版)

Description

Now please write a program to verify Goldbach's conjecture.

Given an odd number nn, output 33 primes whose sum equals the input odd number.

Input Format

Only one line, containing a positive odd integer nn, where 9<n<200009 < n < 20000.

Output Format

Only one line, output 33 primes whose sum equals the input odd number. Adjacent primes are separated by a single space, and there is no space after the last prime. If the representation is not unique, output the scheme with the smallest first prime. If there are multiple such schemes, output the one that also has the smallest second prime.

2009
3 3 2003

Hint

Translated by ChatGPT 5