Codeforces Round #387 (Div. 2) A
来源:互联网 发布:淘宝联盟 高佣金 编辑:程序博客网 时间:2024/06/02 02:33
这个题思路没错,但是要似乎出bug了
我在cf上交过了,在vj上交错了
看了数据,一带是对的,不知哪里出错了。。
还是用sqrt写吧
代码如下
#include<cstdio>#include<iostream>#include<algorithm>#include<cstring>#include<cmath>using namespace std;int main(){int n;scanf("%d",&n);int p=sqrt(n);for( ;p>=1;p--){if(n%p==0) break;}printf("%d %d\n",p,n/p); }
阅读全文
0 0
- Codeforces Round #387 (Div. 2) A---D
- Codeforces Round #387 (Div. 2) A
- Codeforces Round #387(Div. 2)A. Display Size【暴力】
- Codeforces Round #387 (Div. 2) A+B+C+D!
- Codeforces Round #387 (Div. 2)A. Display Size(水题)
- Codeforces Round #387 (Div. 2) 747A Display Size
- Codeforces Round #387 (Div. 2) A. Display Size
- Codeforces Round #131 (Div. 2) A B
- Codeforces Round #174 (Div. 2) Problem A
- Codeforces Round #173 (Div. 2) A.Bit++
- Codeforces Round #181 (Div. 2) A题
- Codeforces Round #184 (Div. 2) A题
- Codeforces Round #185 (Div. 2)--A,B
- Codeforces Round #172 (Div. 2) A题
- Codeforces Round #166 (Div. 2) A题
- Codeforces Round #132 (Div. 2) A题
- Codeforces Round #131 (Div. 2) A题
- Codeforces Round #133 (Div. 2) A题
- 快速排序5分钟快速学习(小白指南)
- Java数据类型
- MacBook上 MySql 修改初始密码
- 远程仓库maven 下载失败 XXX.jar.lastUpdated
- 使用pytesseract出现错误:“[WinError 2] 系统找不到指定的文件
- Codeforces Round #387 (Div. 2) A
- 欢迎使用CSDN-markdown编辑器
- 最小生成树——Prim算法
- 203. Remove Linked List Elements
- 一个简单实用的的加载动画(跳点效果)
- PostgreSQL递归查询
- [python]返回每个分组的top_n
- 数据库六大约束用法:主键(primary key)、外键(foreign key)、非空(not null)、默认(default)、检查(check)、唯一(unique)
- java 解析ttf字体文件