当前位置:网站首页>L1-024 the day after tomorrow (5 points)
L1-024 the day after tomorrow (5 points)
2022-07-04 07:29:00 【Inter personal liabilities^】
L1-024 The day after tomorrow (5 branch )
If today is Wednesday , The day after tomorrow is Friday ; If today is Saturday , The day after tomorrow is Monday . We use Numbers 1 To 7 Monday to Sunday . Given a day , Please export that day “ The day after tomorrow ” What day is .
Input format :
The first line of input gives a positive integer D
(1 ≤ D
≤ 7), Represents a day of the week .
Output format :
Output in one line D
What day is the day after tomorrow .
sample input :
3
sample output :
5
AC Code
#include<iostream>
#include<algorithm>
#include<cstring>
#include<cmath>
#include<vector>
#include<stack>
#include<queue>
#include<sstream>
using namespace std;
typedef long long ll;
const int N=100010;
int main()
{
int n;
cin >> n;
n += 2;
if(n != 7) n %= 7;
cout << n << endl;
return 0;
}
边栏推荐
- How to input single quotation marks and double quotation marks in latex?
- Used on windows Bat file startup project
- Node foundation ~ node operation
- [real case] how to deal with the failure of message consumption?
- 手写简易版flexible.js以及源码分析
- Zephyr study notes 2, scheduling
- Literature collation and thesis reading methods
- Guoguo took you to write a linked list, and the primary school students said it was good after reading it
- I was pressed for the draft, so let's talk about how long links can be as efficient as short links in the development of mobile terminals
- Node connection MySQL access denied for user 'root' @ 'localhost' (using password: yes
猜你喜欢
Tri des fonctions de traitement de texte dans MySQL, recherche rapide préférée
The number of patent applications in China has again surpassed that of the United States and Japan, ranking first in the world for 11 consecutive years
Four sets of APIs for queues
How to send mail with Jianmu Ci
Introduction to spark core components
Data double write consistency between redis and MySQL
节点基础~节点操作
There is no Chinese prompt below when inputting text in win10 Microsoft Pinyin input method
Book list | as the technical support Party of the Winter Olympics, Alibaba cloud's technology is written in these books!
com. alibaba. nacos. api. exception. NacosException
随机推荐
2022 - 021arts: début du deuxième semestre
2022-021rts: from the second half of the year
CMS source code of multi wechat management system developed based on thinkphp6, with one click curd and other functions
【森城市】GIS数据漫谈(一)
Boosting the Performance of Video Compression Artifact Reduction with Reference Frame Proposals and
输入年份、月份,确定天数
博客停更声明
Computer connects raspberry pie remotely through putty
Unity 从Inspector界面打开资源管理器选择并记录文件路径
Adaptive spatiotemporal fusion of multi-target networks for compressed video perception enhancement
Redis - detailed explanation of cache avalanche, cache penetration and cache breakdown
The number of patent applications in China has again surpassed that of the United States and Japan, ranking first in the world for 11 consecutive years
Would you like to go? Go! Don't hesitate if you like it
Vulhub vulnerability recurrence 77_ zabbix
Two years ago, the United States was reluctant to sell chips, but now there are mountains of chips begging China for help
【FreeRTOS】FreeRTOS学习笔记(7)— 手写FreeRTOS双向链表/源码分析
Rapidjson reading and writing JSON files
Blue Bridge Cup Quick sort (code completion)
MySQL 数据库 - 函数 约束 多表查询 事务
It's healthy to drink medicinal wine like this. Are you drinking it right