Unlike FORTRAN, the most used types of data in the C programming language are integers, reals, and single characters represented by int, float, and char respectfully. The primary focus of this chapter is on the use of these data types.
Data type conversions are used to aid in the formatting of the input and output of data in a similar fashion as FORTRAN's FORMAT statement. Examples of many of these are provided in sample programming statements.
The scanf function which allows the input of data is then introduced, and its use is illustrated in example programs. As in FORTRAN, it is important to know and understand integer division and variable type conversion to avoid errors in calculation. This is the last topic covered in this chapter.
Have a look at the sample programs for this chapter
Come back to the main page