adspace
Answer Posted / Suman Nagar
The "register" keyword in C++ is used to request that the compiler to store the variable in a register instead of main memory (RAM). The primary purpose of using register variables is to increase the performance by reducing the number of memory accesses. However, the actual placement of variables in registers is determined by the compiler and not all variables requested as "register" will be stored in the registers because registers are limited in number.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers