CodeForces 659A Round House(水题)
来源:互联网 发布:影响二次销售 淘宝介入 编辑:程序博客网 时间:2024/05/29 14:27
题意:有一个环,你在a处,问你走b步之后你在哪里
思路:注意b为负数的情况就好了
#include<bits/stdc++.h>using namespace std;int main(){ long long n,a,b; cin>>n>>a>>b;a--; a=a+100*n; a=a+b; cout<<a%n+1<<endl;}
0 0
- CodeForces 659A Round House(水题)
- Codeforces 659A Round House【水题,细节】
- 【CodeForces】[659A]Round House
- 【Codeforces】659A - Round House
- CodeForces-659A-Round House
- CodeForces 659A Round House
- CodeForces 659A Round House
- codeforces 659A Round House
- CodeForces - 659A Round House (形成环)水
- Codeforces 659A:Round House(模拟,转化)
- CodeForces 659 A. Round House(简单数学推理)
- Codeforces 659A Round House (模拟)
- Codeforces 659A Round House 【小数学】
- CodeForces 659A Round House(技巧)
- Codeforces Round #346 (Div. 2) -A. Round House(模拟)
- Codeforces Round #408 A. Buying A House
- CodeForce 659A - Round House(水题)
- Codeforces Round #346 (Div. 2)--A. Round House
- JFinal框架简单学习
- 第5周项目1 三角形4
- smdk210 构建根文件系统
- C语言编程在Xcode中Scanf 输入跳过以及清空键盘缓冲区总结
- 读取文件中的内容
- CodeForces 659A Round House(水题)
- 二级指针作输入之内存模型二
- 十二、平衡二叉树(2-3查找树、红黑二叉树)
- vmware 虚拟机下 ubuntu 与主机共享锐捷
- Android之NDK开发
- 关于JWT
- 对SQL Server的操作
- 两个有序数组元素之积、和的最小K个值
- Matlab中三维直方图的显示方法