Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


#include<stdio.h>
void main()
{
int a [5];
for (i=0; i<=4; i++)
printf(ā€œ%dā€ ,a[i]);
}

Answers were Sorted based on User's Feedback



#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / kalyan chukka

Here it shows i is undefined Symbol.So if declare i as
integer then it prints some garbage value Because Array is
declared but elements are not inserted into the array.So
garbage value is printed on the console

Is This Answer Correct ?    10 Yes 1 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / neelima

it gives a garbage values

Is This Answer Correct ?    10 Yes 2 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / sameer mohammed

It shows us garbage values as because the integer type
array is declared but it is not defined.

Is This Answer Correct ?    6 Yes 2 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / jayakrishna

here array a is declared but it is not initialised,but int
the printf we are printing values of array a[], so it
displays garbage values & cannot directly write i as
variable we must specify its type.

Is This Answer Correct ?    4 Yes 1 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / tanvi jain

as i is not yet declared,so give an error.

Is This Answer Correct ?    0 Yes 0 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / purnima

it gives compile time error because here the var i is not
declared .aIn c a var must be declared before is usage

Is This Answer Correct ?    0 Yes 1 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / guest

0
1
2
3
4

Is This Answer Correct ?    0 Yes 5 No

#include<stdio.h> void main() { int a [5]; for (i=0; i<=4; i++) printf(ā€..

Answer / kapil

1 2 3 4 5

Is This Answer Correct ?    3 Yes 14 No

Post New Answer

More C Interview Questions

What is Memory leakage ?

2 Answers   HCL,


Write a progarm to find the length of string using switch case?

0 Answers   TCS,


Explain what a Binary Search Tree is.

3 Answers  


Is it possible to use curly brackets ({}) to enclose single line code in c program?

0 Answers  


4) Write a program that takes a 5 digit number and calculates 2 power that number and prints it. i have done maximum par but i m findind problem in the commented area. please help...

3 Answers  


What is meant by type casting?

0 Answers  


How macro execution is faster than function ?

0 Answers   Wipro,


How would you write qsort?

1 Answers  


How to Clear last bit if it 1 using Macro TURN_OFF_BIT_LAST

6 Answers   Adobe, Huawei,


Rapunzel walks into the forest of forgetfullness. She meets a Lion who lies on Monday Tuesdays and Wednesdays and meets a rabbit who lies on Thurs fridays and saturdays . On that day both say that "I lied yesterday". What day is it .

3 Answers   TCS,


what is the answer for it main() { int i; clrscr(); printf("%d",&i)+1; scanf("%d",i)-1; }

3 Answers  


How can I find out how much memory is available?

1 Answers   Persistent,


Categories