ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories  >>  Software  >>  Programming Languages  >>  C
 
 


 

 
 C interview questions  C Interview Questions
 C++ interview questions  C++ Interview Questions
 VC++ interview questions  VC++ Interview Questions
 Delphi interview questions  Delphi Interview Questions
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions
Question
IS  STRUCTURES CAN BE USED WITHIN AN ARRAY?
 Question Submitted By :: Venugopal
I also faced this Question!!     Rank Answer Posted By  
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 1
YES ,THEY CAN BE,BECAUSE ARRAY CAN HOLD SIMILAR DATA 
TYPED   ONES,WE ARE USING ONLY STRUCTURE VARIABLES 
THEMSELVES.IT WILL BE POSSIBLE.
 
Is This Answer Correct ?    3 Yes 0 No
Venugopal
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 2
yes. structures can be used within an array. variables are 
declared in an arrays in structures.
 
Is This Answer Correct ?    0 Yes 0 No
E-mail
 
 
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 3
Yes... Sure...
 
Is This Answer Correct ?    0 Yes 0 No
Sathish
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 4
no
 
Is This Answer Correct ?    0 Yes 0 No
Mathan
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 5
No. Because arrays are homogeneous datatype and 
 structures are heterogeneous datatype. So we cann't
 
Is This Answer Correct ?    0 Yes 1 No
Swamy S T
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 6
yesss.

we do used structures within arrays..

struct student
{
  char name[20];
  int roll_no;
}s[10]

this is array of structures..

we use "."(dot) operator to access the element
s[i].name = ""
s[i].roll_no = ...
 
Is This Answer Correct ?    2 Yes 1 No
Shruti
 
  Re: IS STRUCTURES CAN BE USED WITHIN AN ARRAY?
Answer
# 7
generally in turbo c++ 3.0 to above version it can't
possible but possible if we declared float linking point
declaration 
in such way globally after header file 
             float a,*b;
               b=&a;
after this declaration structure can take array
 
Is This Answer Correct ?    0 Yes 0 No
Biranchi Parida
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
write a program to search for an element in a given array. If the array was found then display its position otherwise display appropriate message in c language  3
How to reverse a string using a recursive function, without swapping or using an extra memory? Motorola18
when will be evaluated as true/ if(x==x==x) a) x=1; b) x=0; c) x=-1; d) none HCL4
write a own function to compare two strings with out using stringcomparition function? LG-Soft3
what will be the result of the following program ? char *gxxx() { static char xxx[1024]; return xxx; } main() { char *g="string"; strcpy(gxxx(),g); g = gxxx(); strcpy(g,"oldstring"); printf("The string is : %s",gxxx()); } a) The string is : string b) The string is :Oldstring c) Run time error/Core dump d) Syntax error during compilation e) None of these IBM2
Write a program to generate prime factors of a given integer?  1
Can I pass constant values to functions which accept structure arguments?  2
what is the difference between NULL & NUL keywords in C?  3
Which of the following data structures is on average the fastest for retrieving data: 1) Binary Tree 2) Hash Table 3) Stack  3
Please list all the unary and binary operators in C.  1
2. What is the function of ceil(X) defined in math.h do? A)It returns the value rounded down to the next lower integer B)it returns the value rounded up to the next higher integer C)the Next Higher Value D)the next lower value Accenture2
identify the in correct expression a.a=b=3=4; b.a=b=c=d=0; float a=int b=3.5; d.int a; float b; a=b=3.5; TCS5
Write a c code segment using a for loop that calculates and prints the sum of the even integers from 2 to 30, inclusive?  2
#define f(x) main() { printf("\n%d",f(2+2)); }  3
What will be result of the following program? void myalloc(char *x, int n) { x= (char *)malloc(n*sizeof(char)); memset(x,\0,n*sizeof(char)); } main() { char *g="String"; myalloc(g,20); strcpy(g,"Oldstring"); printf("The string is %s",g); } a) The string is : String b) Run time error/Core dump c) The string is : Oldstring d) Syntax error during compilation e) None of these IBM3
Given an array of characters, how would you reverse it? How would you reverse it without using indexing in the array?  1
In scanf h is used for BFL2
Which of the Following is not defined in string.h? A)strspn() B)strerror() C)memchr() D)strod() Accenture1
Would you rather wait for the results of a quicksort, a linear search, or a bubble sort on a 200000 element array? 1) Quicksort 2) Linear Search 3) Bubble Sort  2
main() { float a=3.2e40; printf("%d",a); } Satyam5
 
For more C Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com