hdu-1194 Beat the Spread!
来源:互联网 发布:php setlocale 编辑:程序博客网 时间:2024/05/22 08:37
#include<stdio.h>int main(){ int s,n,d,x,y; scanf("%d",&n); while(n--) { int flag=0; scanf("%d%d",&s,&d); if(s<d) flag=1; if((s+d)%2!=0) flag=1; x=(s+d)/2; y=s-x; if(flag==1) printf("impossible\n"); else printf("%d %d\n",x>y?x:y,x>y?y:x); } return 0;} 注意特殊数据100 1,这道题还是比较简单的
0 0
- HDU 1194 Beat the Spread!
- HDU 1194 Beat the Spread!
- HDU 1194Beat the Spread!
- HDU 1194 Beat the Spread!
- hdu 1194 Beat the Spread!
- hdu-1194 Beat the Spread!
- hdu 1194 Beat the Spread!(水题)
- hdu-oj 1194 Beat the Spread!
- 杭电 HDU 1194 Beat the Spread!
- HDU 1194 Beat the Spread!(数学)
- HDU 1194 Beat the Spread! 【水题+细心】
- 1194:Beat the Spread!
- 1194 Beat the Spread!
- [1194]:Beat the Spread!
- HDOJ 1194 Beat the Spread!
- HDOJ 1194 Beat the Spread!
- HDOJ 1194 Beat the Spread!
- POJ 2301 && HDU 1194 Beat the Spread!(水~)
- hdu-1170 Balloon Comes!
- ubuntu如何安装Mac OS X主题
- vim环境配置spf13
- 轻量级JavaEE企业应用实战(七)
- python注释
- hdu-1194 Beat the Spread!
- EventBus详解
- SQL Server 导入和导出 命令打开向导
- 【jQuery】使用toggle()方法绑定多个函数
- android开发的记录
- autocode的demo
- hdu-1196 Lowest Bit
- Android Activity 启动/退出 动画效果
- Undefined symbols for architecture armv7: "std::_List_node_base::hook(std::_List_node_base*)", refer