403. Scientific Problem

Time limit per test: 0.25 second(s)
Memory limit: 65536
kilobytes
input: standard
output: standard

Once
upon a time Professor Idioticideasinventor was travelling by train.
Watching cheerless landscape outside the window, he decided to invent
the theme of his new scientific work. All of a sudden a brilliant idea
struck him: to develop an effective algorithm finding an integer number,
which is x times less than the sum of all its integer positive predecessors, where number x is given. As far as he has no computer in the train, you have to solve this difficult problem.

Input

The first line of the input file contains an integer number x (1 ≤ x ≤ 109).

Output

Output an integer number — the answer to the problem.

Example(s)
sample input
sample output
1
3
sample input
sample output
2
5
 #include<iostream>
#include<string.h>
#include<stdio.h>
#include<ctype.h>
#include<algorithm>
#include<stack>
#include<queue>
#include<set>
#include<math.h>
#include<vector>
#include<map>
#include<deque>
#include<list>
using namespace std;
int main()
{
int x;
scanf("%d",&x);
printf("%d\n",*x+);
return ;
}

SGU 403 Scientific Problem的更多相关文章

  1. SGU - 403 - Scientific Problem (水)

    403. Scientific Problem Time limit per test: 0.25 second(s) Memory limit: 65536 kilobytes input: sta ...

  2. 找规律 SGU 107 987654321 problem

    题目地址:http://acm.sgu.ru/problem.php?contest=0&problem=107 /* 题意:n位数的平方的后面几位为987654321的个数 尼玛,我看描述这 ...

  3. SGU 205. Quantization Problem

    205. Quantization Problem time limit per test: 0.25 sec. memory limit per test: 65536 KB input: stan ...

  4. SGU 107 987654321 problem【找规律】

    题目链接: http://acm.sgu.ru/problem.php?contest=0&problem=107 题意: 平方后几位为987654321的n位数有多少个 分析: 虽然说是水题 ...

  5. 数论 - SGU 107 987654321 problem

    987654321 problem Problem's Link Mean: 略 analyse: 这道题目是道简单题. 不过的确要好好想一下: 通过简单的搜索可以知道,在N<9时答案一定为0, ...

  6. sgu 107 987654321 problem

    其实挺水的,因为两个数平方,只有固定的后面几位数会影响到最后结果的后面几位数.也就是说,如果想在平方之后尾数为987654321,那么就有固定的几个尾数在平方后会是这个数,打个表,发现 10^8 内 ...

  7. SGU 403 Game with points

    408. Game with points Time limit per test: 0.25 second(s)Memory limit: 65536 kilobytes input: standa ...

  8. 数论 - SGU 105 DIV3

    SGU 105-DIV 3 Problem's Link Mean: 定义这样一种数列:1,12,123.. 给出一个n,求这个数列中能被3整除的数的个数. analyse: 这道题可以用分析的方法解 ...

  9. SGU 乱搞日志

    SGU 100 A+B :太神不会 SGU 101 Domino: 题目大意:有N张骨牌,两张骨牌有两面有0到6的数字,能相连当且仅当前后数字相同,问能否有将N张骨牌连接的方案?思路:裸的欧拉回路,注 ...

随机推荐

  1. 【记录】尝试用QEMU模拟ARM开发板去加载并运行Uboot,kernel,rootfs【转】

    转自:https://www.crifan.com/try_use_qemu_emulate_arm_board_to_load_and_run_uboot_kernel_rootfs/ [背景] 手 ...

  2. 2013 NEERC

    2013 NEERC Problem A. ASCII Puzzle 题目描述:完成一个拼图. solution 暴搜,但好像挺难打的,但听说因为题目限制比较多,其实很多奇怪的情况都不存在. Prob ...

  3. 使用postman做接口测试(一)

    参考大神的总结:https://www.cnblogs.com/Skyyj/p/6856728.html 一,先了解一下基础知识,虽然工作中没什么卵用,但背会了,可以显摆自己很专业的样子,以下内容来自 ...

  4. 003_Mac挂载NTFS移动硬盘读取VMware虚拟机文件

    一.Mac 挂载NTFS移动硬盘进行读写操作 (Read-only file system) 注意如下图所示先卸载,然后按照下图的命令进行挂载.然后cd /opt/003_vm/   &&am ...

  5. spring 学习之二 AOP编程

    AOP概念 AOP, aspect oriented programing,翻译过来就是面向切面编程的意思,那什么叫面向切面编程呢?相对于之前传统的纵向继承方式来对原有功能进行功能扩展, 面向切面编程 ...

  6. CentOS/Linux 网卡设置 IP地址配置

    CentOS/Linux下设置IP地址 1:临时修改:1.1:修改IP地址# ifconfig eth0 192.168.100.100 1.2:修改网关地址# route add default g ...

  7. SCTP客户端与服务器

    /** * @brief - Send a message, using advanced SCTP features * The sctp_sendmsg() function allows you ...

  8. 自己动手编译OpenSSL库

    因为工作需要,要实现一个基于SSL的通信程序.之前没有接触过SSL协议通讯,这次学习了一下如何自己编译OpenSSL库. 我使用的环境是Windows 10 + VS2015 1.首先打开VS2015 ...

  9. 制作Label标签文件时,使用convert_imageset.exe的注意事项

    当前的convert_imageset.exe版本做了一下修改 //status = ReadImageToDatum(root_folder + lines[line_id].first, //li ...

  10. 转:springboot(二):web综合开发

    web开发 spring boot web开发非常的简单,其中包括常用的json输出.filters.property.log等 json 接口开发 在以前的spring 开发的时候需要我们提供jso ...