Character Set

The most basic and indivisible unit of the language is the character. The set of characters used to form COBOL character-strings and separators includes the letters of the alphabet, digits and special characters, and is defined below:

Character Meaning
0 to 9 Digits
A to Z Upper-case letters
a to z Lower-case letters
  Space
+ Plus sign
- Minus sign or hyphen
* Asterisk
/ Oblique stroke/slash
= Equal sign
$ Dollar sign
. Period or decimal point
, Comma or decimal point
; Semicolon
" Quotation mark
' Apostrophe
( Left parenthesis
) Right parenthesis
> Greater than symbol
< Less than symbol
: Colon
& Ampersand
_ Underscore

Lower-case letters can be used in character strings and text words; except when used in nonnumeric literals and except for some picture symbols, each lower-case letter is equivalent to the corresponding upper-case letter.

This COBOL implementation is restricted to the above character set, but the content of nonnumeric literals, comment lines, comment entries and data can include any of the printable characters available under the character encoding scheme used for the COBOL compilation group. (See the topic Character Sets and Collating Sequences.)