哪里錯(cuò)了呀
#include <stdio.h>
int main()?
{? ? ? ?
? ? int height = 185;
? ? //補(bǔ)全所有代碼
? ? if (height>=180)
? ? {
? ? ? ? printf("%d\n","能加入校隊(duì)");
? ? }
? ? else
? ? {
? ? ? ? printf("%d\n","不能加入");
? ? }
? ??
return 0;
}
#include <stdio.h>
int main()?
{? ? ? ?
? ? int height = 185;
? ? //補(bǔ)全所有代碼
? ? if (height>=180)
? ? {
? ? ? ? printf("%d\n","能加入校隊(duì)");
? ? }
? ? else
? ? {
? ? ? ? printf("%d\n","不能加入");
? ? }
? ??
return 0;
}
2020-04-14
舉報(bào)
2020-04-20
#include <stdio.h>
int main()?
{? ? ? ?
? ? int height = 185;
? ? //補(bǔ)全所有代碼
? ? if (height>=180)
? ? {
? ? ? ? printf("能加入校隊(duì)\n");
? ? }
? ? else
? ? {
? ? ? ? printf("不能加入\n");
? ? }
? ??
return 0;
}
這樣就可以了,%d是格式化輸出,需要在后邊加上要輸出的變量名,而且%d是整數(shù)的占位符,想輸出字符串變量,用%s
2020-08-05
#include <stdio.h>
?main()?
{? ?char a[]="恭喜小明可以參加?;@球隊(duì)";
? ? int height = 185;
? ? if(height>=180)
{
? ? printf("%s",a);
}
? ??
? ??
return 0;
}
這樣就行
2020-04-18
%d為格式化輸出,需要在逗號(hào)后面跟上想輸出的變量名稱(chēng)而不是字符串。
如printf("身高為:%d,能加入校隊(duì)",height);
2020-04-18
你這個(gè)輸出的是文字不是數(shù)
2020-04-14
為什們不能用%d呀