Codeforces Round #355 (Div. 2)C - Vanya and Label
啊啊啊啊啊啊啊,真的是智障了。。。
这种题目,没有必要纠结来源。只要知道它的结果的导致直接原因?反正这句话就我听的懂吧。。。
“>>”/“&”
#include<cstdio>
int main()
{
int ans=1;
for(int i=0;i<=1;i++)
printf("%d\n",ans&i);
ans=0;
for(int i=0;i<=1;i++)
printf("%d\n",ans&i);
ans=12;
for(int j=0;j<6;j++)
{
printf("%d ",(ans>>j));
}
}
贴份代码跑
#include <iostream>
#include <stdio.h>
#include <string.h>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <vector>
#include <math.h>
#include <algorithm>
using namespace std;
#define LL long long
#define INF 0x3f3f3f3f
const double pi = acos(-1.0);
const int mod = 1e9+7;
const int N=1e2+10;
int getch(char c)
{
if(c>='0'&&c<='9')
return c-'0';
if(c>='A'&&c<='Z')
return c-'A'+10;
if(c>='a'&&c<='z')
return c-'a'+36;
if(c=='-')
return 62;
if(c=='_')
return 63;
}
int main()
{
string ss;
cin>>ss;
LL ans=1;
LL x;
for(int i=0;i<ss.size();i++)
{
x=getch(ss[i]);
for(int j=0;j<6;j++)
{
if(!((x>>j)&1))
ans=ans*3%mod;
}
}
cout<<ans<<endl;
}
Codeforces Round #355 (Div. 2)C - Vanya and Label的更多相关文章
- Codeforces Round #355 (Div. 2) C. Vanya and Label 水题
C. Vanya and Label 题目连接: http://www.codeforces.com/contest/677/problem/C Description While walking d ...
- Codeforces Round #355 (Div. 2) D. Vanya and Treasure 分治暴力
D. Vanya and Treasure 题目连接: http://www.codeforces.com/contest/677/problem/D Description Vanya is in ...
- Codeforces Round #355 (Div. 2) B. Vanya and Food Processor 水题
B. Vanya and Food Processor 题目连接: http://www.codeforces.com/contest/677/problem/B Description Vanya ...
- Codeforces Round #355 (Div. 2) A. Vanya and Fence 水题
A. Vanya and Fence 题目连接: http://www.codeforces.com/contest/677/problem/A Description Vanya and his f ...
- Codeforces Round #355 (Div. 2) D. Vanya and Treasure dp+分块
题目链接: http://codeforces.com/contest/677/problem/D 题意: 让你求最短的从start->...->1->...->2->. ...
- Codeforces Round #355 (Div. 2)-B. Vanya and Food Processor,纯考思路~~
B. Vanya and Food Processor time limit per test 1 second memory limit per test 256 megabytes input s ...
- Codeforces Round #355 (Div. 2) D. Vanya and Treasure
题目大意: 给你一个n × m 的图,有p种宝箱, 每个点上有一个种类为a[ i ][ j ]的宝箱,a[ i ][ j ] 的宝箱里有 a[ i ][ j ] + 1的钥匙,第一种宝箱是没有锁的, ...
- Codeforces Round #355 (Div. 2) B. Vanya and Food Processor
菜菜菜!!!这么撒比的模拟题,听厂长在一边比比比了半天,自己想一想,然后纯模拟一下,中间过程检测一下,妥妥的就可以过. 题意:有N个东西要去搞碎,每个东西有一个高度,然后有一台机器支持里面可以达到的最 ...
- 水题 Codeforces Round #308 (Div. 2) A. Vanya and Table
题目传送门 /* 水题:读懂题目就能做 */ #include <cstdio> #include <iostream> #include <algorithm> ...
随机推荐
- Andrew Ng的机器学习视频文件夹(from coursera, 2014)
第一周: 简单介绍机器学习,有监督学习.无监督学习. 1-1,1-2,1-3,1-4 第二周: 2-1:回归问题举例 2-2:介绍cost function定义. 2-3:在回归函数是一个经过原点的直 ...
- js加入收藏夹
工作需要了解了一下点击加入收藏这个功能 <script> function _addFavorite() { var url = window.location; //获取当前网页网址 v ...
- C#实现模拟登录百度并发送私信
首先获取Token,根据Token获取PubliKey,使用RSA加密POST数据 private Regex _regex = new Regex(@"\{.*\}", Rege ...
- php新版本号废弃 preg_replace /e 修饰符
近期serverphp版本号升级到了 5.6 发现出了非常多警告 preg_replace(): The /e modifier is deprecated, use preg_replace_ca ...
- linux 输入子系统(3) button platform driver
button platform driver 一般位于driver/input/keyboard/gpio_keys.c /*用于按键事件的上报,它将在按键的中断发生后被调用.其中逻辑就是获取到按键类 ...
- Apache Qpid 高可用集群
一.RHCS RHCS是Red Hat Cluster Suite(红帽子集群套件)的缩写.RHCS是一个功能完备的集群应用解决方案,它从应用的前端访问到后端的数据存储都提供了一个行之有效的集群架构实 ...
- BZOJ 4976: 宝石镶嵌 背包
4976: 宝石镶嵌 Time Limit: 2 Sec Memory Limit: 128 MB Description 魔法师小Q拥有n个宝石,每个宝石的魔力依次为w_1,w_2,...,w_n ...
- 在C++中使用Libmd5计算字符串或文件的MD5值
CppMD5Demo.cpp #include <iostream> #include <fstream> #include <chrono> #include & ...
- 使用jsoncpp解析生成json
在此站点下载jsoncpp(https://sourceforge.net/projects/jsoncpp/这个站点的版本较旧) 在电脑上安装Python,运行amalgamate.py,生成的di ...
- caioj1465&&poj1024: 【AC自动机】地图匹配
刷的第二题AC自动机,这题简直了.. 用询问的串建AC自动机,然后...爆搜! ACBB ACBBACCA A AABBC ...