请帮助解决这个问题并解释逻辑.我不知道&运营商是如何在这里工作的.
void main() {
int a = -1;
static int count;
while (a) {
count++;
a &= a - 1;
}
printf("%d", count);
}
Run Code Online (Sandbox Code Playgroud) 为什么以下程序输出5?
#include <stdio.h>
main()
{
char str[]="S\065AB";
printf("\n%d", sizeof(str));
}
Run Code Online (Sandbox Code Playgroud) 我是指针概念的新手..我不明白以下程序..请告诉我这个程序的逻辑..
function (int *p,int *q){
return(*p = (*p + *q) - (*q = *p));
}
int main(){
int y = 15, z = 25;
function(&y, &z);
printf("%d\t%d", z, y);
}
Run Code Online (Sandbox Code Playgroud)