Codeforces Round #422 A. I'm bored with life
来源:互联网 发布:lol遇到一个网络问题 编辑:程序博客网 时间:2024/05/16 07:46
题目网址: Codeforces Round #422 A. I’m bored with life
题意分析:
- 题意:求 gcd(a!, b!)
- 分析显然最大公约数就是 min(a!, b!)
代码:
#include <iostream>#include <algorithm>using namespace std;int main(int argc, char const *argv[]){ int a, b; int ans, mn; while (~scanf("%d %d", &a, &b)) { ans = 1; mn = min(a, b); while (mn) { ans *= mn; --mn; } printf("%d\n", ans); } return 0;}
阅读全文
1 0
- Codeforces Round #422 A. I'm bored with life
- Codeforces Round #422 (Div. 2) A I'm bored with life
- Codeforces Round #422 (Div. 2) A. I'm bored with life
- codeforces 822 A I'm bored with life
- CodeForces 822A I'm bored with life
- codeforces 822A(I'm bored with life) Java
- Codeforces 822A I'm bored with life
- I'm bored with life (Codeforces 822A)
- codeforces 822A I'm bored with life
- Codeforces822 A I'm bored with life
- A. I'm bored with life
- A. I'm bored with life
- I'm bored with life
- I'm bored with life
- 0706 CF#822A-I'm bored with life #822B-Crossword solving
- I'm bored~~~
- I found a bug with CCParticleSystem.m
- Codeforces Round #380A - Interview with Oleg
- Github没有记录Contributions的原因及解决方案
- 每日一题——栈实现队列,队列实现栈
- 使用Ansible部署Nginx
- Spring源码(一) 源码转换eclipse工程
- 【Java Utility】Jsoup网页爬虫工具--设置Element的HTML内容【十二】
- Codeforces Round #422 A. I'm bored with life
- mysql学生选课
- 【JavaScript的条件操作符】
- 探索ES6 Iterator(遍历器)
- 栈的应用
- Struts framework的工作原理和组件
- 深度学习的最好方案,FPGA或GPU?
- 讲课大师 把微信消息同步转发到企业微信中
- Codeforces Round #422 B. Crossword solving