How to access or modify the const variable in c ?
Answer Posted / varunreddy
try this it will work:
#include<stdio.h>
int main()
{
const int i=10;
*(int *)&i=i++;
printf("%d\n",i);
return 0;
}
Is This Answer Correct ? | 3 Yes | 3 No |
Post New Answer View All Answers
What is the concatenation operator?
How #define works?
Why functions are used in c?
write a program in c language to print your bio-data on the screen by using functions.
How many levels of pointers have?
What is an operator?
Explain how to reverse singly link list.
What is use of #include in c?
What is the scope of global variable in c?
Can you assign a different address to an array tag?
What is the difference between text and binary modes?
What is the meaning of 2d in c?
How do you determine the length of a string value that was stored in a variable?
Badboy is defined who has ALL the following properties: Does not have a girlfriend and is not married. He is not more than 23 years old. The middle name should be "Singh" The last name should have more than 4 characters. The character 'a' should appear in the last name at least two times. The name of one of his brothers should be "Ram" Write a method: boolean isBadBoy(boolean hasGirlFriend , boolean isMarried, int age , String middleName , String lastName , String[] brotherName); isHaveGirlFriend is true if the person has a girlfriend isMarried is true if the person is married age is the age of the person middleName is the middle name of the person lastName is the last name of the person brotherName is the array of the names of his brothers
Differentiate between functions getch() and getche().