程序代码:
#include<stdio.h> #include<stdlib.h> int check_sys() { int n = 1; return *((char*)&n); } int main() { int ret = check_sys(); if (ret = 1) { printf("little\n"); } else { printf("big\n"); } system("pause"); return 0; }
运行结果:
little
请按任意键继续. . .
本文出自 “10910765” 博客,请务必保留此出处http://10920765.blog.51cto.com/10910765/1737458
原文:http://10920765.blog.51cto.com/10910765/1737458