2: Scripts
( \newcommand{\kernel}{\mathrm{null}\,}\)
So far we’ve typed all of our programs “at the prompt.” If you’re only writing a few lines, this isn’t so bad. But what if you’re writing a hundred? Retyping each line of code every time you want to change or test your program will be time-consuming and tedious. Luckily, you don’t have to. In this chapter, we’ll look at a way to run many lines at once: scripts.