ZOJ1414 POJ1663 Number Steps 很简单的找规律题
来源:互联网 发布:战地1淘宝代购 编辑:程序博客网 时间:2024/04/30 07:57
很简单,找规律。。。
/******************************************************************************* * Author : Neo Fung * Email : neosfung@gmail.com * Last modified : 2011-07-31 11:32 * Filename : ZOJ1414 POJ1663 Number Steps.cpp * Description : * *****************************************************************************/// ZOJ1414 POJ1663 Number Steps.cpp : Defines the entry point for the console application.//// #include "stdafx.h"#include <fstream>#include <stdio.h>#include <iostream>#include <string.h>#include <string>#include <vector>#include <stack>#include <queue>#include <deque>#include <map>#include <math.h>#include <algorithm>#include <numeric>#include <functional>#include <memory.h>using namespace std;int main(void){// ifstream cin("data.txt");int ncases;int x,y;cin>>ncases;while(ncases--){cin>>x>>y;if (x==y){if (x%2){cout<<x*2-1<<endl;} else{cout<<x*2<<endl;}}else if (x-y==2){if (x%2){cout<<x+y-1<<endl;} else{cout<<x+y<<endl;}} else{cout<<"No Number"<<endl;}}return 0;}
- ZOJ1414 POJ1663 Number Steps 很简单的找规律题
- poj1663(找规律,水题啊啊)
- ZOJ1414 Number Steps
- ZOJ1414 Number Steps
- zoj1414 Number Steps
- HDU 1391 Number Steps【找规律】
- HDU 1391 Number Steps(数学题+找规律)
- 【POJ】1663 - Number Steps(找规律)
- HDOJ1393 Number Steps(找规律)
- HDU 1391 Number Steps(思维题目,找规律)
- hdu 4279 Number 简单题目 找规律
- codeforce(找规律的简单题)
- ZOJ1414题的解法
- Steps——找规律
- hdoj1021简单题、找规律
- hdoj1005简单题、找规律
- hdoj1061简单题、找规律
- hdoj1097简单题、找规律
- 系统调用-文件访问
- 什么是自由软件?
- 转:学习linux和unix编程
- Windows Socket IO 模型
- poj2363-blocks
- ZOJ1414 POJ1663 Number Steps 很简单的找规律题
- Java中引用类型和原始类型的区分
- POJ1256 Anagram STL中的next_permutation()
- Q_CHECK_PTR and “fscanf float or double”
- 字符串中的||去掉
- nmon 的使用
- Qt学习——布局管理器QLayout类
- GetPixel SetPixel bitbil
- Makefile 入门