In recent years, C has become the programming language most often chosen by serious programmers; those who program for a living. C's rich set of operators and library functions allows programmers to write powerful, concise, and elegant code. Furthermore, C compilers exist for virtually every type of computer, and C programs are portable between different types of computers. Perhaps the main advantage of C over other programming languages is its versatility. On the one hand, C is a powerful general-purpose language that supports structured and modular programming languages; but at the same time, it provides access to lower-level facilities that most other languages hide from the programmer. Essential Cis intended for students who have had no prior programming experience. Providing a simple and brief introduction to programming in C makes this text suitable for a first semester, freshman level course. Only the basics a students needs to understand and write useful C programs are presented and explanations using computer jargon are avoided. Examples are referred to whenever possible. The topics have been carefully chosen for their relevance to practical scientific and engineering programming. Although the text is written with the scientific and engineering students in mind, it should be suitable in other disciplines as well.
1. Introduction 2. Integer Data 3. Floating-Point Data 4. The Standard Mathematics Library 5. Flow of Control: Selection 6. Flow of Control: Repetition 7. User-Defined Functions 8. Functions and Call by Reference 9. Arrays 10. Two-Dimensional Arrays 11. Character Data 12. Strings 13. Simple File I/O 14. C Shortcuts and Idioms Appendix A. Operator Precedence and Associativity Appendix B. Standard Mathematical Functions Appendix C. Matrix Algebra Appendix D. ASCII and EBCDIC Character Codes