CodeForces 606A Magic Spheres
水题
/* ***********************************************
Author :Zhou Zhentao
Email :774388357@qq.com
Created Time :2015/12/15 12:45:27
File Name :main.cpp
************************************************ */ #include <stdio.h>
#include <string.h>
#include <iostream>
#include <algorithm>
#include <vector>
#include <queue>
#include <set>
#include <map>
#include <string>
#include <math.h>
#include <stdlib.h>
#include <time.h>
using namespace std; int a,b,c;
int x,y,z;
int flagA,flagB,flagC;
int flag2; int main()
{
while(~scanf("%d%d%d",&a,&b,&c))
{
scanf("%d%d%d",&x,&y,&z); flagA=,flagB=,flagC=,flag2=; int num=; if(a>=x) flagA=flagA+a-x;
else flag2=flag2+x-a; if(b>=y) flagB=flagB+b-y;
else flag2=flag2+y-b; if(c>=z) flagC=flagC+c-z;
else flag2=flag2+z-c; num=num+flagA/;
num=num+flagB/;
num=num+flagC/; if(num>=flag2) printf("Yes\n");
else printf("No\n");
}
return ;
}
CodeForces 606A Magic Spheres的更多相关文章
- codeforce 606A - Magic Spheres
题意:a,b,c三种球,能把俩个一样的球变成另一颜色不一样的球.给你目标x,y,z,问能否经过变化至少达打目标. #include<iostream> #include<stdio. ...
- Codeforces Round #335 (Div. 2) A. Magic Spheres 水题
A. Magic Spheres Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://www.codeforces.com/contest/606/ ...
- 【CodeForces 606A】A -特别水的题1-Magic Spheres
http://acm.hust.edu.cn/vjudge/contest/view.action?cid=102271#problem/A Description Carl is a beginne ...
- Codeforces Round #335 (Div. 2) A. Magic Spheres 模拟
A. Magic Spheres Carl is a beginner magician. He has a blue, b violet and c orange magic spheres. ...
- CodeForces--606A --Magic Spheres(模拟水题)
Magic Spheres Time Limit: 2000MS Memory Limit: 262144KB 64bit IO Format: %I64d & %I64u Submi ...
- Codeforces 710C. Magic Odd Square n阶幻方
C. Magic Odd Square time limit per test:1 second memory limit per test:256 megabytes input:standard ...
- Codeforces 670D1. Magic Powder - 1 暴力
D1. Magic Powder - 1 time limit per test: 1 second memory limit per test: 256 megabytes input: stand ...
- [递推+矩阵快速幂]Codeforces 1117D - Magic Gems
传送门:Educational Codeforces Round 60 – D 题意: 给定N,M(n <1e18,m <= 100) 一个magic gem可以分裂成M个普通的gem ...
- CodeForces 670D2 Magic Powder 二分
D2. Magic Powder - 2 The term of this problem is the same as the previous one, the only exception — ...
随机推荐
- DataBinding
<?xml version="1.0" encoding="utf-8"?> <layout xmlns:android="http ...
- 安装mongodb到系统服务
一定要以管理员身份打开命令窗口; d盘 创建一个mongodb文件夹,里面有个data文件夹,data里面有db文件夹和log文件夹 mongodb文件夹里面还有个文件mongod.cfg 内容如下 ...
- PHP安装后php-config命令干嘛的
php-config 是一个简单的命令行脚本用于查看所安装的 PHP 配置的信息. 我们在命令行执行 php-config 会输出所有的配置信息 Usage: /usr/local/php/bin/p ...
- wpf之ListBox横向显示所有ListBoxItem
Xaml: <Window x:Class="WpfApplication6.MainWindow" xmlns="http://schemas.microsoft ...
- java操作oracle的blob,clob数据
一.区别和定义 LONG: 可变长的字符串数据,最长2G,LONG具有VARCHAR2列的特性,可以存储长文本一个表中最多一个LONG列 LONG RAW: 可变长二进制数据,最长2G CLOB: ...
- WNDCLASS 窗口类结构
Windows 的窗口总是基于窗口类来创建的,窗口类同时确定了处理窗口消息的窗口过程(回调函数). 在创建应用程序窗口之前,必须调用 RegisterClass 函数来注册窗口类.该函数只需要一个参数 ...
- Hibernate 系列教程3-单表操作
工程截图 hibernate.cfg.xml <!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Conf ...
- 在Activity之间使用Intent传值和Bundle传值的区别和方式
两者本质上没有任何区别.Bundle只是一个信息的载体 将内部的内容以键值对组织 Intent负责Activity之间的交互 自己是带有一个Bundle的Intent.putExtras(Bundle ...
- HDU1969:Pie(二分)
Pie Time Limit : 5000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other) Total Submissio ...
- dos命令创建安卓签名
1.dos下进入到jdk安装目录的bin目录, 如:C:\Program Files\Java\jdk1.7.0_79\bin 2.输入命令格式如: keytool -genkey -alias aa ...