Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What is a const pointer, and how does it differ from a pointer to a const?

Answers were Sorted based on User's Feedback



What is a const pointer, and how does it differ from a pointer to a const?..

Answer / nashiinformaticssolutions

1. Pointer to const: The value being pointed to cannot be modified, but the pointer itself can change.
Example:
2. const int a = 10;
3. const int *ptr = &a; // *ptr is read-only
4. const pointer: The pointer cannot change, but the value it points to can.

Is This Answer Correct ?    0 Yes 0 No

What is a const pointer, and how does it differ from a pointer to a const?..

Answer / glibwaresoftsolutions

1. Pointer to const: The value being pointed to cannot be modified, but the pointer itself can change.
Example:
2. const int a = 10;
3. const int *ptr = &a; // *ptr is read-only
4. const pointer: The pointer cannot change, but the value it points to can.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Interview Questions

What math functions are available for integers? For floating point?

0 Answers  


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

0 Answers  


What does %2f mean in c?

0 Answers  


What is the package for freshers(Non IIT) in amazon(hyderabad). And what is the same for those who are a contract employee.

0 Answers  


In how much time you will write this c program? Prime nos from 1 to 1000

2 Answers   TCS,


What is the purpose of the code, and is there any problem with it? unsigned int f( unsigned n ) { return –n & 7; }

1 Answers   Google,


Why calloc is better than malloc?

0 Answers  


How do you generate random numbers in C?

0 Answers  


If null and 0 are equivalent as null pointer constants, which should I use?

0 Answers  


How do you convert a decimal number to its hexa-decimal equivalent.Give a C code to do the same

0 Answers   Amazon,


what is the main use of c where it can use the c

2 Answers   Infosys,


Why isnt there a numbered, multi-level break statement to break out

0 Answers  


Categories