CS 1100 Lecture 4: August 26, 2016 Notes
Document Summary
A variable can hold multiple values at the same time. Instead of hard coding something, we would rather get input from the user. So that we can accept a number from the user while the program is running. Way we get input from the user is to use a scanner object. In this context, scanning is getting an input from the user, no actually scanning a paper or a page. A scanner is a class from the java library. To check something out from the java library, we have to import it. We must add a line above our class to be able to use a scanner. Import is a keyword to check out something from the library. This line tells where the scanner class is located. A package is a grouping of related classes in the java library. Once, scanner is imported, it must be set up before it"s used.