Hi, this is Kevin White. Welcome back to a new lesson. During this lesson, you'll be able to code COBOL components. Know what characters, words, clauses, and entries are and how they're used and discover and understand three different ways that numbers are stored on mainframe files. First we're going to take a look at characters which make words that are used in clauses to finish entries. A character is the basic or atomic unit of coding that uses any of the following A-Zs, a-zs, the numbers 0-9 and a hyphen character. Now let's provide some more. Although not all details. Here are lots of other characters that you're going to find on your keyboard that they're used as different characters that have some kind of a meaning. COBOL coding components also have a word. A word can use up to 30 characters in it. A word is used to identify a file, a procedure, and data variables. There's a couple of rules though, for word. A word must be preceded by and followed by one or more spaces. A word cannot begin and cannot end with a hyphen, which is why the first example there of Kermit the Frog is not going to work. That's why it says bad word. A clause is used to specify attributes of a field. Field attributes can be a place to store numbers, a number itself, a place to put things like names, towns, cities. Let's look at some examples. There's three examples here. Starting with the first one, we see a picture clause that's used to identify what kind of a character is going to be stored in the data variable that's called employee address. Notice that there's a letter X, which means alphanumeric, which basically means anything you can find on your keypad and how many characters you're going to have there, which is 42 of them. In the second example, we have a current balance. The current balance shows how much money we have in our banking account. It is simply $77 and 50 cents. Notice that it does not have apostrophes at the beginning and at the end, numbers do not. In the third example, we have a town called the town of Mansfield, Connecticut. Notice that it does have apostrophes surrounding it. This is giving us information about the employee-city. An entry is a series of clauses that ends with a period as it's delimiter. Here is an example. Notice that numbers again do not have quotes around them, but somebody's name does have quotes around them. That would be Lynn with single quotes around her name. Remember, characters, make words that are used in clauses to finish entries. We saw some examples of COBOL programs using picture clauses and usage clauses. We'll expand on this in another lesson, but in the meantime, we're going to see how data categories are used. This includes numbers. We have three different kinds of numbers that are stored in COBOL. The first one is decimal, the second one is binary, and the third one is hexadecimal. Let's break these down into individual ones, starting with decimal numbers. Decimal numbers have 10 digits to work with. What I was taught is that we start with the number 0 and we finish with the number 9. This gives us 10 different digits. Let's take a look at binary numbers. Binary numbers only have two digits to work with a zero and a one. Yes, you heard that right. Does this chart look a little goofy? Let's put it side-by-side with decimal numbers so we can compare the two. On the left-hand side we have the numbers that most of us have learned, on the right-hand side are the binary numbers where only zeros and ones can be used. You'll notice that once the one gets used, the next one is going to show up a little bit to its left and so on. Thirdly, we have hexadecimal numbers. We've put these different kinds of numbers side-by-side, starting with decimal on the far left-hand side, binary in the middle, and hexadecimal on the right-hand side. You might notice with hexadecimal that we have the digits 0-9, and then we've run out of digits. Starting with the number 10, we're going to represent that using the letter A and the number 11 with letter B and so on. We're only going to take it as far as the number 15 that gets to the letter F. As we finish this section, we are now able to code COBOL components. Know what characters, words, clauses, and entries are and how they get used and discover and understand three different ways numbers are stored, decimal, binary, and hexadecimal until next time.