Skip to content

ProfoundAdvice

Answers to all questions

Menu
  • Home
  • Trendy
  • Most popular
  • Helpful tips
  • Life
  • FAQ
  • Blog
  • Contacts
Menu

What will be the address of the ARR?

Posted on January 7, 2021 by Author

Table of Contents

  • 1 What will be the address of the ARR?
  • 2 Why a 5 ]= 5 a ]? Explain?
  • 3 Why does int arr[4] have no value?
  • 4 What is * (* (* (*(arr + i ) + j ) + k) )?

What will be the address of the ARR?

Discussion Forum

Que. What will be the address of the arr[2][3] if arr is a 2-D long array of 4 rows and 5 columns and starting address of the array is 2000?
b. 2056
c. 2052
d. 2042
Answer:2052

How can you find out the address of a particular index if elements are stored in column major order in a two dimensional array?

By Column major order If array is declared by a[m][n] where m is the number of rows while n is the number of columns, then address of an element a[i][j] of the array stored in row major order is calculated as, Address(a[i][j]) = ((j*m)+i)*Size + BA.

Are is an example of type memory location?

Discussion Forum

Que. Array is an example of _______ type memory allocation.
b. Run Time
c. Depends on the Compiler
d. None of the above
Answer:Compile Time
READ:   How much do cad designers make UK?

Why a 5 ]= 5 a ]? Explain?

This is the direct artifact of arrays behaving as pointers, “a” is a memory address. The address of this element is “a + 5”. This is equal to offset “a” from “5” elements at the beginning of the address space (5 + a).

Is there any difference in below declarations int fun int arr 5 INT fun int arr?

Is there any difference int the following declarations? Explanation: No, both the statements are same. It is the prototype for the function fun() that accepts one integer array as an parameter and returns an integer value.

Is there any difference in below declarations int fun int arr 5 int fun int arr?

Why does int arr[4] have no value?

By just declaring int arr [4] you are simply creating a reference. Because it is never assigned a value, the values at where this reference points to doesn’t change. This is because C is an explicit language. So the values there are the values of whatever previously held the memory arr [4] is using.

READ:   When did Brian Quinn break his ribs?

What is the difference between arr[5] and &arr[2] =?

If we have an array[5], we know that arr = &arr[0] but what is &arr[2] =? In a C based language, &arr[0]is a pointer to the first element in the array while &arr[2]is a pointer to the third element in the array.

What is the value of ARR + 1 in 1D array?

So we can say that arr points to the 0 th 1-D array, arr + 1 points to the 1 st 1-D array and arr + 2 points to the 2 nd 1-D array. Since arr + i points to i th element of arr, on dereferencing it will get i th element of arr which is of course a 1-D array.

What is * (* (* (*(arr + i ) + j ) + k) )?

The name of the array arr is a pointer to the 0 th 2-D array. Thus the pointer expression * (* (* (arr + i ) + j ) + k) is equivalent to the subscript expression arr [i] [j] [k]. We know the expression * (arr + i) is equivalent to arr [i] and the expression * (* (arr + i) + j) is equivalent arr [i] [j].

Popular

  • Can DBT and CBT be used together?
  • Why was Bharat Ratna discontinued?
  • What part of the plane generates lift?
  • Which programming language is used in barcode?
  • Can hyperventilation damage your brain?
  • How is ATP made and used in photosynthesis?
  • Can a general surgeon do a cardiothoracic surgery?
  • What is the name of new capital of Andhra Pradesh?
  • What is the difference between platform and station?
  • Do top players play ATP 500?

Pages

  • Contacts
  • Disclaimer
  • Privacy Policy
© 2025 ProfoundAdvice | Powered by Minimalist Blog WordPress Theme
We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept All”, you consent to the use of ALL the cookies. However, you may visit "Cookie Settings" to provide a controlled consent.
Cookie SettingsAccept All
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT