经典c程序00例5.docVIP

  • 3
  • 0
  • 约 7页
  • 2016-12-03 发布于河南
  • 举报
经典c程序00例5

【程序51】 题目:学习使用按位与 。    1.程序分析:00=0; 01=0; 10=0; 11=1 2.程序源代码: #include stdio.h main() { int a,b; a=077; b=a3; printf(\40: The a b(decimal) is %d \n,b); b=7; printf(\40: The a b(decimal) is %d \n,b); } ============================================================== 【程序52】 题目:学习使用按位或 | 。 1.程序分析:0|0=0; 0|1=1; 1|0=1; 1|1=1             2.程序源代码: #include stdio.h main() { int a,b; a=077; b=a|3; printf(\40: The a b(decimal) is %d \n,b); b|=7; printf(\40: The a b(decimal) is %d \n,b); } ============================================================== 【程序53】 题目:学习使用按位异或 ^ 。    1.程序分析:0^0=0; 0^1=1; 1^0

文档评论(0)

1亿VIP精品文档

相关文档