How does the 'register' keyword affect the storage of a variable in a C program?
- It's allocated in a CPU register
- It's allocated in the data segment
- It's allocated in the heap
- It's allocated in the stack
The 'register' keyword suggests to the compiler to store the variable in a CPU register, which can lead to faster access. However, it's just a hint, and the compiler may choose to ignore it.
Loading...
Related Quiz
- The ________ keyword in C is used to give a reference to a variable that is already defined in some other scope.
- The ________ function is used to move the file pointer to a specified position in a file.
- What is the function of the #define preprocessor directive in a C program?
- What is the primary function of pointers in C?
- To resize a previously allocated memory block, the function ________ is used in C.