Interviewer And Interviewee Guide

Data Structure Arrays Interview Question:

What is two-dimensional array?

Submitted by: Administrator
An array with two dimensions is called as a two-dimensional array. It is also called as a matrix. In C, a two dimensional array is initialized as int arr[nb_of_rows] [nb_of_columns]. Hence, two dimensional arrays can be considered as a grid. An element in a two dimensional can be accessed by mentioning its row and column. If the array has 20 integer values, it will occupy 80 bytes in memory (assuming 4 bytes for an integer). All of the bytes are in consecutive memory locations, the first row occupying the first 20 bytes, the second the next 20, and so on.
Submitted by: Administrator

Read Online Data Structure Arrays Job Interview Questions And Answers
Copyright 2007-2024 by Interview Questions Answers .ORG All Rights Reserved.
https://InterviewQuestionsAnswers.ORG.