112A
#include <iostream>
#include <string>
#include <cctype>
using namespace std;
int main()
{
string str1;
string str2;
int length;
while(cin>>str1>>str2)
{
length=str1.size();
int i;
for(i=0; i<length; ++i)
{
str1[i]=tolower(str1[i]);
str2[i]=tolower(str2[i]);
if((str1[i]-'0')>(str2[i]-'0'))
{
cout<<1<<endl;
break;
}
else if((str1[i]-'0') < (str2[i]-'0'))
{
cout<<-1<<endl;
break;
}
}
if(i==length)
cout<<0<<endl;
}
return 0;
}
112A的更多相关文章
- Linux系统升级更新openssh 7.3p1
放在最前面:鉴于网上爬虫猖獗,博客被盗时有发生,这里需要来个链接,大家请认准来自博客园的Scoter:http://www.cnblogs.com/scoter2008,本文将持续更新 最近绿盟给扫描 ...
- User Login Client Identification
w用HTTP认证首部注册用户名. HTTP The Definitive Guide Rather than passively trying to guess the identity of a u ...
- PatentTips - Reducing Write Amplification in a Flash Memory
BACKGROUND OF THE INVENTION Conventional NAND Flash memories move data in the background to write ov ...
- PatentTips - Enhanced I/O Performance in a Multi-Processor System Via Interrupt Affinity Schemes
BACKGROUND OF THE INVENTION This relates to Input/Output (I/O) performance in a host system having m ...
- 探究机器码,深入研究C语言程序的机制
用C高级编程语言写的程序,都要经过编译链接成本机可执行的程序.这个可执行程序究竟是什么呢?在Linux上,我们可以用objdump命令很方便地查看一个可执行程序的机器码.我们从一个简单的示例开始,说一 ...
- 硬件vendor id查询对照列表
Hex-ID Vendor Name003D Lockheed Martin Corp0E11 Compaq1000 Symbios Logic Inc.1001 KOLTER ELECTRONIC1 ...
随机推荐
- C语言程序设计--文件操作
前言 这里尝试与Python对别的方法来学习C语言的文件操作,毕竟我是Pythoner. 文件打开与关闭 Python #因为是和C语言比对,所以不使用with filename = "/e ...
- 二进制安装mysql
1.1 MySQL安装介绍 mysql软件下载地址信息: www.mysql.com mirrors.sohu.com mysql软件下载完毕后,查看mysql解压后目录文件大小 1.下载解压my ...
- db2 查杀死锁进程
db2 查杀死锁进命令 db2 get snapshot for locks on (需要snapshot的访问权限) db2 list applications db2 "force ap ...
- 洛谷P1316 丢瓶盖【二分】【贪心】
题目:https://www.luogu.org/problemnew/show/P1316 题意: 给定a个点的坐标(在一条直线上),现在要选b个点,问这b个点的最近距离的最大值是多少. 思路: 感 ...
- ubuntu16.04下安装配置pl-svo
Semi-direct Visual Odometry(SVO)安装配置 https://blog.csdn.net/seymour163/article/details/53947764 http: ...
- 关于Dosbox0.74无法使用masm命令
今天尝试在dosbox里编译asm源代码文件 但是提示“illegal command”,也就是非法命令 开始还以为我的dosbox版本不对 但是去网上查阅资料发现别人用这个版本都可以使用 所以百思不 ...
- 最详细最全的redis配置文件解释
转载自:http://www.cnblogs.com/zhang-ke/p/5981108.html #redis.conf# Redis configuration file example.# . ...
- Struts2 框架使用 核心以及其他详细配置
因为在使用SSH框架的过程,关于struts2的配置比较繁琐,所以做个总结. 一.导入并且关联其他XML 1. 因为在核心配置文件(Struts2.xml)中,如果存在很多需要配置的Action项 ...
- centos7.2 nfs安装配置
nfs服务端 ip:192.168.1.16 1.yum -y install rpcbind nfs-utils 2.创建文件/etc/exports,内容如下 /mnt/ 192.168.1.0/ ...
- A pointer is a variable whose value is the address of another variable 指针 null pointer 空指针 内存地址0 空指针检验
小结: 1.指针的实际值为代表内存地址的16进制数: 2.不同指针的区别是他们指向的变量.常量的类型: https://www.tutorialspoint.com/cprogramming/c_po ...