Java Reference
In-Depth Information
public static void main(String[] args) {
foo();
public static void foo() {
System.out.println("foo");
}
bar();
public static void bar() {
baz();
public static void baz() {
System.out.println("baz");
}
System.out.println("bar");
}
System.out.println("mumble");
}
Finally, we have finished our picture of the flow of control of this program. It
should make sense, then, that the program produces the following output:
foo
baz
bar
mumble
We will see a much more useful example of methods calling methods when we go
through the case study at the end of the chapter.
Did You Know?
The New Hacker's Dictionary
Computer scientists and computer programmers use a lot of jargon that can be
confusing to novices. A group of software professionals spearheaded by Eric
Raymond have collected together many of the jargon terms in a book called The
New Hacker's Dictionary. You can buy the topic, or you can browse it online at
Eric's website: http://catb.org/esr/jargon/html/frames.html.
For example, if you look up foo, you'll find this definition: “Used very gen-
erally as a sample name for absolutely anything, esp. programs and files.” In
Continued on next page
Search WWH ::




Custom Search