返回题库

最接近平方根的因子分解

Smallest Factorizaiton

专题
Brainteaser / 脑筋急转弯
难度
L4

题目详情

数 12345678901234567890 不是质数,因此可以写成 abab(a,ba,b 为正整数)。

求 a∗+b∗a^*+b^*,其中 a∗b∗=1234567890a^*b^*=1234567890,且对任意其它满足 ab=1234567890ab=1234567890 的因子对,都有

∣a−b∣≥∣a∗−b∗∣.|a-b|\ge |a^*-b^*|.

提示:可考虑质因数分解。

英文原题

The number 12345678901234567890 is not prime, so it can be written in the form abab for two positive integers aa and bb. Find a∗+b∗a^* + b^*, where a∗a^* and b∗b^* satisfy a∗b∗=1234567890a^*b^* = 1234567890 and for any other pair (a,b)(a,b) such that ab=1234567890ab = 1234567890, ∣a−b∣≥∣a∗−b∗∣|a-b| \geq |a^* - b^*|. It may be helpful to consider the prime factorization.

解析

要使 ∣a−b∣|a-b| 最小,相当于让 a,ba,b 尽量接近 N\sqrt{N}。

枚举 a≤1234567890a\le \sqrt{1234567890} 的所有因子可得最接近的一对为

(a∗,b∗)=(34227, 36070).(a^*,b^*)=(34227,\ 36070).

因此

a∗+b∗=70297.\boxed{a^*+b^*=70297}.

英文解析

To minimize ∣a−b∣|a-b| is to keep a,ba,b as close as possible to N\sqrt{N}.

The closest possible pair of all factors to enumerate a≤1234567890a\le \sqrt{1234567890} is

(a∗,b∗)=(34227,\36070).(a^*,b^*)=(34227,\36070).

Therefore,

a∗+b∗=70297.\boxed{a^*+b^*=70297}.