文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>C语言实例5:位运算

C语言实例5:位运算

时间:2010-06-18  来源:hnrainll

#include <stdio.h>

int main()
{
    unsigned char result;

    int a, b, c, d;
    a = 2;
    b = 4;
    c = 6;
    d = 8;

    result = a & c;
    printf("result = %d\n",result);

    result = b | d;
    printf("result = %d\n",result);

    result = a ^ d;
    printf("result = %d\n",result);

    result = ~a;
    printf("result = %d\n",result);


    while(1);

    return 0;
}


相关阅读 更多 +
排行榜 更多 +
别惹神枪手安卓版

别惹神枪手安卓版

冒险解谜 下载
坦克战争世界

坦克战争世界

模拟经营 下载
丛林反击战

丛林反击战

飞行射击 下载