Switch and For Statements, Command Line and File Handling - Introduction

Chapter chap9 section 1

In this chapter we will see how to process the command line arguments that will enable us to write C programs that can be used in the same way as normal operating system commands. We will also see how to do some elementary handling of files from within programs rather than using host system input and output redirection.

Before we do that, however, we are going to look at two C language statements that we have not discussed previously. These are the for and switch statements.