FUNDAMENTALS OF COMPUTER

COMPUTER PROGRAMMING FUNDAMENTALS

WHAT IS PROGRAMMING

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
A ____ is a named location in memory that stores a value that does not change during the program
A
literal
B
sentinel
C
variable
D
constant
Explanation: 

Detailed explanation-1: -Answer: A variable is a named memory location which temporarily stores data that can change while the program is running. A constant is a named memory location which temporarily stores data that remains the same throughout the execution of the program.

Detailed explanation-2: -A variable is a named location in the computer’s memory, used to store a piece data (or information).

Detailed explanation-3: -Constant is a named memory location used to hold a value that CANNOT be changed during the script execution. If a user tries to change a Constant value, the script execution ends up with an error. Constants are declared the same way the variables are declared.

Detailed explanation-4: -Variables are nothing but reserved memory locations to store values. This means that when you create a variable you reserve some space in memory. Based on the data type of a variable, the interpreter allocates memory and decides what can be stored in the reserved memory.

There is 1 question to complete.