What will be output of the program?
#include <stdio.h>
#include <conio.h>
void main()
{
int arr[3] = {3};
int i;
for(i = 0; i <= 2; i++)
printf("%d, ", arr[i]);
getch();
}
#include <stdio.h>
#include <conio.h>
void main()
{
int arr[3] = {3};
int i;
for(i = 0; i <= 2; i++)
printf("%d, ", arr[i]);
getch();
}
3, 0, 0,
3, 3, 3,
3, garbage, garbage
Another
Hãy suy nghĩ và trả lời câu hỏi trước khi xem đáp án
Tổng hợp câu hỏi trắc nghiệm lập trình C/C++ có đáp án và lời giải đầy đủ nhằm giúp các bạn dễ dàng ôn tập lại toàn bộ các kiến thức.