Using Variables and Assignment

Programs manipulate data values. Whether a program performs a single calculation—such as, say, converting a temperature value from Fahrenheit to Celsius—reads data only to display it, or performs much more complex calculations and interactions, the values a program manipulates must be both accessible and assignable. Accessible means that a value must reside somewhere in computer memory and should be retrievable. Assignable means a value or the result of a calculation must be stored somewhere in computer memory to be later retrieved. Each value has a data type and a named location where it is stored. These can either be variables or constants.

Variables, or non-constant variables, hold values that are the ...

Get Learn C Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.