摘要: 括弧,这是一个错误的做法,并不能AC 题目描述 Byteasar wants to put a rather long pattern on his house. In order to do this, he has to prepare an appropriate template with 阅读全文
posted @ 2017-06-14 17:48 LoveYayoi 阅读(267) 评论(0) 推荐(0) 编辑
摘要: 简单题意:给出x(x<=1e9),求一组包含x的勾股数 我好像没什么思路啊,先分类讨论吧 首先x是斜边: x^2 = a^2+b^2 似乎除了枚举a没有什么好办法 再试试x是直角边 a^2+x^2=b^2 试着把式子变形 (b+a)(b-a) = x^2 这个就好办了,我们考虑把x^2分成两个数的积 阅读全文
posted @ 2017-06-14 16:56 LoveYayoi 阅读(164) 评论(0) 推荐(0) 编辑
摘要: D. Two Arithmetic Progressions time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You are gi 阅读全文
posted @ 2017-06-14 15:25 LoveYayoi 阅读(204) 评论(0) 推荐(0) 编辑