UVa213
来源:互联网 发布:手机app软件下载 编辑:程序博客网 时间:2024/05/22 16:47
#define LOCAL0#include <stdlib.h>#include <stdio.h>#include "iostream"#include "sstream"#include <string.h>#include <cmath>#define inf 0x3f3f3f3fusing namespace std;char tbl[8][(1<<7)-1];int getCode(char *s, int &pos, int len){int tot=0;char ch;while(len){ch=s[pos++];tot=tot+(ch-'0')*int(pow(2,len-1));--len;}return tot;}int main(){ #ifdef LOCAL freopen("input.txt","r",stdin); //freopen("output.txt","w",stdout); #endif int i,n,ch; memset(tbl,0,sizeof(tbl)); for(i=1;i<8;i++){ for(n=0;n<int(pow(2,i)-1);n++){ if((ch=getchar())!='\n') tbl[i][n]=ch; else break; } if(ch=='\n') break; } int l,pos=0,k; char s[1024]; scanf("%s",s); while((l=getCode(s,pos,3))!=0){ while((k=getCode(s,pos,l))!=int(pow(2,l)-1)){ cout<<tbl[l][k]; } putchar('\n'); } printf("END\n"); return 0;}
0 0
- UVa213
- UVa213
- UVa213
- UVa213
- UVa213
- UVA213 - Message Decoding
- uva213信息解码
- 例题4-4 uva213
- UVa213 Message Decoding
- UVa213 - Message Decoding
- UVA213----Message Decoding
- UVA213 UVALive5152 Message Decoding
- Uva213信息解码
- UVa213-信息解码
- uva213解题报告
- UVa213-Message Decoding
- UVa213 Message Decoding
- UVa213 Message Decoding
- ANDROID开发之SQLite详解
- 图像匹配
- Hash Collisions (The Poisoned Message Attack) "The Story of Alice and her Boss"
- RedHat使用sudo出错
- c++ vector 释放内存
- UVa213
- Java Properties
- sgu103
- shell循环loop
- hybris学习笔记:Trail ~ Testing the DAO
- c考试
- interview - 事件分发机制总结
- ubuntu安装配置搜狗拼音输入法
- Java 内联函数