GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

GeekInterview.com  >  Placement Papers  >  TCS  >  Aptitude
Go To First  |  Previous Question  |  Next Question 
 Aptitude  |  Question 63 of 147    Print  
4.In two dimensional array X(7,9) each element occupies 2 bytes of memory.If the address of first element X(1,1)is 1258 then what will be the address of the element X(5,8) ?
whats the ans

  
Total Answers and Comments: 7 Last Update: April 26, 2008     Asked by: pavan 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
September 28, 2006 04:08:35   #1  
vinayak        

RE: 4.In two dimensional array X(7,9) each element occ...

ans is  1344


 
Is this answer useful? Yes | No
September 30, 2006 08:50:08   #2  
naveen        

RE: 4.In two dimensional array X(7,9) each element occ...
Ans is 1344 and it is calculated asfirst add 8 since in first row 8 elements then for the next 3 row add 9 nd for the last row add 8 so the total comes to 43 multiply with 2 add it to 1258 it gives 1344
 
Is this answer useful? Yes | No
October 05, 2006 00:39:07   #3  
ajay        

RE: 4.In two dimensional array X(7,9) each element occ...
it should be 1330 according to me
 
Is this answer useful? Yes | No
October 05, 2006 21:09:21   #4  
joseprabhu        

Aspirant.

Hi ,

Can any one explain this with proper steps


 
Is this answer useful? Yes | No
November 30, 2006 11:03:20   #5  
vishal        

RE: 4.In two dimensional array X(7,9) each element occ...

intger req. 2 byte for memory allocation so in this two dim array 7x9 it req. 126 bytes memory.

so 1x1 starting add is 1258.

now to find add of 5x8 so it req 80 byes

so 80+1258=1338.


 
Is this answer useful? Yes | No
January 24, 2007 04:30:13   #6  
prashant kara        

RE: 4.In two dimensional array X(7,9) each element occ...
here, the address of first element x[1][1] is 1258 and also 2 byte of memory is given.now, we have to solve the address of element x[5][8], therefore, 1258+ 5*8*2 = 1258+80 = 1338 so the answer is 1338.
 
Is this answer useful? Yes | No
April 26, 2008 22:19:55   #7  
imran4108 Member Since: April 2008   Contribution: 1    

RE: 4.In two dimensional array X(7,9) each element occupies 2 bytes of memory.If the address of first element X(1,1)is 1258 then what will be the address of the element X(5,8) ? whats the ans
formulae is
X(5,8)=X(N,M)
X(7,9)=X(R,C)
X(5,8)=BASE+C*(M-1)*SIZE+(N-1)*SIZE
WHERE SIZE=2BYTES
BASE=1258
X(5,8)=1258+9*7*2+4*2

 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 




About Us  |   Privacy Policy  |   Terms and Conditions  |   Contact  |   Site Map  |   Add Question  |   Propose Category  |   RSS Feeds  |   Articles Sitemap  |   Site Updates  |   Add Resource

Copyright © 2005 - 2008 GeekInterview.com. All Rights Reserved
Page copy protected against web site content infringement by Copyscape