J. W. Rider
10 May 2001
Every composition, however great or simple, whether in a natural language or in a computer programming language, is created from a handful of primitive components. It is the job of the writer or the programmer to put these "atoms" of language together to form larger "molecules".

When you were younger, you may have learned that English was composed of seven parts of speech. Every word you'd ever write or read or say or hear was one of the following:



Parts of Speech

Verbs
Nouns
Pronouns
Adjectives
Adverbs
Prepositions
Conjunctions
As you learn a new programming language, every recognizable symbol within a computer program takes on a special meaning. Programmers have much latitude in how they arrange the basic elements to develop software, but every symbol falls into the following:



Basic Elements of Java

Comments inline
/* ... */
end-of-line
// ...
javadoc
/** ... */

Literals numbers
987  076  0xfedc
1.2 -3.4e5 67.8e-9
characters
'a'  '\n'  \u000a
strings
"Hello"  "\"quoted\""

Identifiers literals
true  false  null
reserved keywords
public  class  static
standard identifiers
String  System
user-defined
MyHello  args
operators
new  instanceof

Punctuation operators
= + - * / %
== != < >=
separators
. , ;
grouping
() [] {}

1