CF456B.Fedya and Maths
普及-
通过率:0%
时间限制:1.00s
内存限制:256MB
AC君温馨提醒
该题目为【codeforces】题库的题目,您提交的代码将被提交至codeforces进行远程评测,并由ACGO抓取测评结果后进行展示。由于远程测评的测评机由其他平台提供,我们无法保证该服务的稳定性,若提交后无反应,请等待一段时间后再进行重试。
题目描述
Fedya studies in a gymnasium. Fedya's maths hometask is to calculate the following expression:
(1_n_ + 2_n_ + 3_n_ + 4_n_) mod 5
for given value of n. Fedya managed to complete the task. Can you? Note that given number n can be extremely large (e.g. it can exceed any integer type of your programming language).
费佳在一所中学读书。费佳的数学家庭作业是计算如下表达式:
(1n + 2n + 3n + 4n) mod 5
其中 n 是给定的值。费佳已经完成了这项任务。你也能做到吗?注意:给定的数 n 可能极大(例如,它可能超出你所用编程语言中任何整数类型的表示范围)。
输入格式
The single line contains a single integer n (0 ≤ n ≤ 10105). The number doesn't contain any leading zeroes.
单行包含一个整数 n(0 ≤ n ≤ 10105)。该数字不包含任何前导零。
输出格式
Print the value of the expression without leading zeros.
打印该表达式的值,不带前导零。
输入输出样例
输入#1
4
输出#1
4
输入#2
124356983594583453458888889
输出#2
0
说明/提示
Operation x mod y means taking remainder after division x by y.
Note to the first sample:

运算 xmody 表示 x 除以 y 后所得的余数。
第一个样例的说明:

输入解题思路,AI测评打分。不知道怎么写?