Mình có đoạn mã C++:
#include <iostream>
using namespace std;
int main()
{
cout << true << endl;
cout << false << endl;
cout << boolalpha << endl;
cout << true << endl;
cout << false << endl;
system("pause");
return 0;
}
Mình muốn chuyển nó sang C thì làm sao?
Mình thử:
#include<stdio.h>
int main()
{
printf("%d",true);
printf("%d",false);
//or
printf(true);
printf(false);
}
đều không được.