寄托天下 寄托天下
查看: 928|回复: 2

[数学] OG 余数问题 [复制链接]

Rank: 6Rank: 6

声望
53
寄托币
4252
注册时间
2016-10-26
精华
0
帖子
762

寄托兑换店纪念章 寄托16周年纪念勋章 2016 US-applicant

发表于 2017-7-19 00:24:25 |显示全部楼层
When the positive integer n is divided by 3, the remainder is 2 and when n is divided by 5, the remainder is 1. What is the least possible value of n?

请问这种余数问题,只能通过“硬”算来解题吗?

引用自:
https://gre.magoosh.com/forum/36 ... nteger-n-is-divided

We have,
3x + 2 = n
5y + 1 = n (x & y being their respective quotient)

Therefore, 3x + 2 = 5y + 1
3x = 5y - 1
x = (5y - 1)/3

Now we know that, 5y - 1 is divisible by 3, so lets substitute y = 0, 1, or 2

Trying these values we find y = 2

3x = 5(2) - 1
3x = 9
x = 3

n = 3x + 2 = 9 + 2 = 11
n = 5y + 1 = 10 + 1 = 11

Thus 11 is the least possible value of n


这种方式也是逐个来试验的
回应

使用道具 举报

Rank: 4

声望
65
寄托币
665
注册时间
2013-7-12
精华
0
帖子
112

寄托16周年纪念勋章

发表于 2017-7-19 06:24:55 |显示全部楼层
本帖最后由 阿之 于 2017-7-19 06:26 编辑

我的解法的话:
因为是5的倍数+1:第一个是5*1+1 = 6,但是6/3=2,不满足第一条件;
第二个是5*2+1 = 11,11/3=3余2,满足第一条件
所以是11.

也可以用3再算一次检查。

使用道具 举报

Rank: 6Rank: 6

声望
53
寄托币
4252
注册时间
2016-10-26
精华
0
帖子
762

寄托兑换店纪念章 寄托16周年纪念勋章 2016 US-applicant

发表于 2017-8-8 17:27:21 |显示全部楼层
阿之 发表于 2017-7-19 06:24
我的解法的话:
因为是5的倍数+1:第一个是5*1+1 = 6,但是6/3=2,不满足第一条件;
第二个是5*2+1 = 11, ...

谢谢,看来还是要一次次的去尝试验算

使用道具 举报

RE: OG 余数问题 [修改]
您需要登录后才可以回帖 登录 | 立即注册

问答
Offer
投票
面经
最新
精华
转发
转发该帖子
OG 余数问题
https://bbs.gter.net/thread-2106913-1-1.html
复制链接
发送
报offer 祈福 爆照
回顶部