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                      
Do you have a collection of Interview Questions and interested to share with us!!
Please send that collection to along with your userid / name. ThanQ
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
if the address of a[1,1] and a[2,1] are 1000 and 1010 
respectively and each occupies 2 bytes then the array has 
been stored in what order?
 Question Submitted By :: Praveen
I also faced this Question!!     Rank Answer Posted By  
 
  Re: if the address of a[1,1] and a[2,1] are 1000 and 1010 respectively and each occupies 2 bytes then the array has been stored in what order?
Answer
# 1
always the 2D array will be stored in column order only , in
C.... so only ,
 it is a must that we must specify the column subscript
however we miss the row subscript.....

thank u
 
Is This Answer Correct ?    0 Yes 0 No
Vignesh1988i
 
  Re: if the address of a[1,1] and a[2,1] are 1000 and 1010 respectively and each occupies 2 bytes then the array has been stored in what order?
Answer
# 2
it's order is a[5,5] because it takes 2 bytes for every
elements i.e a[1,1]=1000  a[1,2]=1002   a[1,3]=1004 
a[1,4]=1006  a[1,5]=1008  a[2,1]=1010..............
 
Is This Answer Correct ?    2 Yes 0 No
....................
 
 
 
  Re: if the address of a[1,1] and a[2,1] are 1000 and 1010 respectively and each occupies 2 bytes then the array has been stored in what order?
Answer
# 3
The order of array cannot be defined as we dont know the 
max size of the array. however we can calculate the column 
subscript of the array as follows-
a[1,1] = 1000, a[1,2] =  1002, a[1,3] = 1004, a[1,4] = 
1006, a[1,5] = 1008.
After this the 2nd row will start as a[2,1] = 1010,  and so 
on.
So we can define the no. of columns, i.e. 5, in this array 
but not the no. of rows.
 
Is This Answer Correct ?    1 Yes 0 No
Parul_Kul
[Labour Punjab]
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
how to print value of e(exp1)up to required no of digits after decimal?  1
Who is invented by c? Infosys14
program for validity of triangle from 3 side  6
Give me basis knowledge of c , c++...  4
what is the output of following question? void main() { int i=0,a[3]; a[i]=i++; printf("%d",a[i] }  2
Given a single Linked list with lakhs of nodes and length unknown how do you optimally delete the nth element from the list? Oracle1
what is calloc and malloc?  1
#include<stdio.h> main() { char s1[]="Ramco"; char s2[]="Systems"; s1=s2; printf("%s",s1); } Find the output CitiGroup4
biggest of two no's with out using if condition statement  2
What character terminates all strings composed of character arrays? 1) 0 2) . 3) END  3
How can I set an array's size at run time?  7
What are the languages are portable and platform independent?Why they are like that? Excel1
CopyBits(x,p,n,y) copy n LSBs from y to x starting LSB at 'p'th position. Adobe4
How do I declare a pointer to an array?  5
what is the use of #pragma pack, wer it is used? Wipro1
#include <stdio.h> int main ( int argc, char* argv [ ] ) { int value1 = 10; int value2 = 5; printf ( "\n The sum is :%d", value1 | value2 ); } This is the answer asked by some one to add two numbers with out using arithmetic operator?Yes this answer is write it given out put as 15.But how????? what is need of following line? int main ( int argc, char* argv [ ] ) how it work?what is the meaning for this line? please explain me.Advance thanks Excel4
How to Clear last bit if it 1 using Macro TURN_OFF_BIT_LAST Adobe2
main() { int x=5; printf("%d %d %d\n",x,x<<2,x>>2); } CitiGroup7
what is real time system?what is the differance between hard and soft real time systems  2
What is false about the following A compound statement is a.A set of simple statments b.Demarcated on either side by curly brackets c.Can be used in place of simple statement d.A C function is not a compound statement. TCS1
 
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