Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我输入了 1111 但它只显示第一个 1 我试图再次卸载并安装 xcode 但它没有工作我该怎么办请帮忙
int main() { int num; printf("input: "); scanf("%d",&num); printf("%d",num); return 0; }
输出
输入:1 1111
输入:1
1111
您应该使用 ObjectiveC 中的初学者教程。
如果你想“打印”一个变量(在这种情况下是整数),你必须这样做:
NSLog(@"My number is %d",num);
如果你想“打印”一个 NSString 你应该这样做:
NSLog(@"My string is %@",String);