#include<stdio.h>

#include<string.h>

char a[300],b[300];

int a1[300],b1[300];

int main() {

int i,j,k,c[300],suma,sumb,lena,lenb;

while(scanf("%s%s",a,b)!=EOF) {

     lena=strlen(a);

  lenb=strlen(b);

  memset(a1,0,sizeof(a1));

  memset(b1,0,sizeof(b1));

  j=0;

  for(i=lena-1;i>=0;i--)

   a1[j++]=a[i]-'A';

   j=0;

   for(i=lenb-1;i>=0;i--)

    b1[j++]=b[i]-'A';

   for(i=0;i<280;i++) {

    a1[i]+=b1[i];

    if(a1[i]>25) {

     a1[i+1]++;

     a1[i]=a1[i]%26;

    }

   }

   k=0;

   for(i=280;i>=0;i--) {

    if(k)

     printf("%c",a1[i]+'A');

    else

     if(a1[i]) {

      k=1;

      printf("%c",a1[i]+'A');

     }

   }

   if(k==0)

    printf("A");

  printf("\n");

}

return 0;

}

hdu 2100的更多相关文章

  1. HDU 2100 分类: ACM 2015-06-17 23:49 15人阅读 评论(0) 收藏

    Lovekey Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Su ...

  2. (string 高精度) Lovekey hdu 2100

    Lovekey Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Su ...

  3. HDU 2100 Lovekey (26进制大数、字符串)

    Lovekey Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Sub ...

  4. Java大数练习第二弹

    hdu1250 水题 题目链接:pid=1250">http://acm.hdu.edu.cn/showproblem.php?pid=1250 import java.util.*; ...

  5. HDU 5047 Sawtooth(大数优化+递推公式)

    http://acm.hdu.edu.cn/showproblem.php?pid=5047 题目大意: 给n条样子像“m”的折线,求它们能把二维平面分成的面最多是多少. 解题思路: 我们发现直线1条 ...

  6. (01背包 排序+特判)饭卡(hdu 2546)

    http://acm.hdu.edu.cn/showproblem.php?pid=2546   Problem Description 电子科大本部食堂的饭卡有一种很诡异的设计,即在购买之前判断余额 ...

  7. HDU——PKU题目分类

    HDU 模拟题, 枚举1002 1004 1013 1015 1017 1020 1022 1029 1031 1033 1034 1035 1036 1037 1039 1042 1047 1048 ...

  8. HDU 1160 DP最长子序列

    G - FatMouse's Speed Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64 ...

  9. HDU 1160 FatMouse's Speed(要记录路径的二维LIS)

    FatMouse's Speed Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) ...

随机推荐

  1. poj 2411 Mondriaan's Dream (轮廓线DP)

    题意:有一个n*m的棋盘,要求用1*2的骨牌来覆盖满它,有多少种方案?(n<12,m<12) 思路: 由于n和m都比较小,可以用轮廓线,就是维护最后边所需要的几个状态,然后进行DP.这里需 ...

  2. Netbeans使用笔记

    Netbeans 新建项目 A brand new project 选择"文件">"新建项目"以打开新建项目向导. 在向导中,选择 "C/C++ ...

  3. iterator与iterable

    用Iterator模式实现遍历集合Iterator模式是用于遍历集合类的标准访问方法.它可以把访问逻辑从不同类型的集合类中抽象出来,从而避免向客户端暴露集合的内部结构.例如,如果没有使用Iterato ...

  4. Example of how to implement a view-based source list (NSOutlineView) using Cocoa Bindings

    You tagged this with the cocoa-bindings tag, so I assume you mean "with bindings." I whipp ...

  5. 如何关闭OSX 10.11 SIP (System Integrity Protection)

    http://www.jianshu.com/p/0572336a0771 注意:SIP功能是Apple在OSX上推出的系统完整性保护功能,对于普通MAC用户来说是一项安全保护功能,如果不了解他的作用 ...

  6. 6.python

    最早的'密码本' ascii 涵盖了英文字母大小写,特殊字符,数字.01010101ascii 只能表示256种可能,太少,创办了万国码 unicode 16表示一个字符不行,32位表示一个字符. A ...

  7. bootstrap历练实例:复选框或单选按钮作为输入框组的前缀或后缀

    <!DOCTYPE html><html><head><meta http-equiv="Content-Type" content=&q ...

  8. XDB基于Library的备份及恢复

    基于standalone全备份 语句: xdb backup --federation xhive://localhost:1235 --standalone --file E:\xdbData\xD ...

  9. Xcode 6 创建 Objective-C category

    1. Command + N 2. 选择 iOS - Source - Objective-C File 3.File Type 选择 Category,Class 填基于的类名,File填扩展的名

  10. URAL1561 Winnie the Pooh

    题目描述: vjudge 题解: 高消(线性基)模$7$. 可以算是板子了. 具体见代码: #include<cstdio> #include<cstring> #includ ...