2017年9月14日

摘要: #include<iostream>using namespace std;int main(){ unsigned short a; short int b=-2; a=b; cout<<"a="<<a<<endl; return 0; } 阅读全文
posted @ 2017-09-14 10:02 三叶癌 阅读(64) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;int main(){ float x; int i; x=3.6; i=(int)x; cout<<"x="<<x<<",i="<<i<<endl; return 0;} 阅读全文
posted @ 2017-09-14 09:51 三叶癌 阅读(78) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;#define price 40 int main() { int num,total; num=10; total=num*price; cout<<"total="<<total<<endl; return 0; } 阅读全文
posted @ 2017-09-14 09:41 三叶癌 阅读(72) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;int main() { char c1,c2; c1='a'; c2='b'; c1=c1-32; c2=c2-32; cout<<c1<<'\n'<<c2<<endl; return 0;} 阅读全文
posted @ 2017-09-14 09:29 三叶癌 阅读(78) 评论(0) 推荐(0)
摘要: #include<iostream>using namespace std;int main() { int i,j; i='A'; j='B'; cout<<i<<'\n'<<j; return 0;} 阅读全文
posted @ 2017-09-14 09:28 三叶癌 阅读(70) 评论(1) 推荐(0)

导航