#include<stdio.h>
int main(){
int a[]={1,2,3,5,1};
int *ptr=a+4;
int y=ptr-a;
printf("%d",y);
}

Answer Posted / sridhar

1

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why isnt any of this standardized in c?

640


What is meant by 'bit masking'?

889


main() { int i = 10; printf(" %d %d %d ", ++i, i++, ++i); }

637


What are register variables? What are the advantage of using register variables?

688


using only #include and #include Write a program in C that will read an input from the user and print it back to the user if it is a palindrome. The string ends when it encounters a whitespace. The input string is at most 30 characters. Assume the string has no spaces and distinguish between and lowercase. So madam is a palindrome, but MadAm is not a palindrome. Use scanf and %s to read the string. Sample Test: Enter a string: madam madam is a palindrome. Enter a string: 09023 09023 is not a palindrome.

1315






What is the difference between exit() and _exit() function in c?

584


What are file streams?

573


What is call by value in c?

559


What functions are used in dynamic memory allocation in c?

598


Is a house a mass structure?

643


Can a variable be both static and volatile in c?

609


What does do in c?

611


where are auto variables stored? What are the characteristics of an auto variable?

596


Is null a keyword in c?

738


What is the difference between memcpy and memmove?

606