How to access or modify the const variable in c ?
Answer Posted / mr.x
int main()
{
const volatile int no=10;
int *ptr;
ptr=(int *)&no;
*ptr=30;
printf("%d %d",no,*ptr);
return 0;
}
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What are structural members?
What are # preprocessor operator in c?
What is abstract data structure in c?
How to write a multi-statement macro?
How is actual parameter different from the formal parameter?
A program is required to print your biographic information including: Names, gender, student Number, Cell Number, line of study and your residential address.
hi folks i m approching for h1 b interview on monday 8th of august at montreal and i m having little problem in my approval notice abt my bithdate my employer has made a mistake while applying it is 12th january and istead of that he had done 18 the of january do any body have any solution for that if yes how can i prove my visa officer abt my real birthdate it urgent please let me know guys thaks dipesh patel
Which is better between malloc and calloc?
shorting algorithmS
What is meant by initialization and how we initialize a variable?
Are the variables argc and argv are always local to main?
What are data types in c language?
Is int a keyword in c?
Tell us bitwise shift operators?
When should structures be passed by values or by references?