Sams Teach Yourself Java™ in 24 Hours (Covering Java 7 and Android)

(singke) #1
ptg

10 HOUR 1:Becoming a Programmer


Q&A
Q. BASIC? C++? Smalltalk? Java? What are the names of these lan-
guages supposed to mean?
A. BASIC gets its name from an acronym that describes what it is:
Beginner’s All Symbolic Instruction Code. C++is a programming lan-
guage that was created to be an improvement on the C language,which
itself was an improvement of the B programming language. Smalltalk is
an innovative object-oriented language developed in the 1970s that had
numerous ideas adopted by Java.
Java goes against the tradition of naming a language with an acronym or
other meaningful term. It’s just the name that Java’s developers liked the
best,beating out WebRunner,Silk,Ruby,and others. When I create my own
programming language,it will be named Salsa. Everybody loves salsa.

Q. Why are interpreted languages slower than compiled ones?
A. They’re slower for the same reason that a person interpreting a live
speech in a foreign language is slower than a translatorinterpreting a
printed speech. The live interpreter has to think about each statement
that’s being made as it happens,while the other interpreter can work
on the speech as a whole and take shortcuts to speed up the process.
Compiled languages can be much faster than interpreted languages
because they do things to make the program run more efficiently.

Q. Do you answer questions only about Java?
A. Not at all. Ask me anything.

Q. Okay,what is the lowest score ever given on Dancing with the Stars?
A. The worst dance by a celebrity contestant on the hit ABC show was per-
formed by the rapper Master P during the second season in 2006. His
Paso Doble with professional dancer Ashly DelGrosso scored a lowest-
ever 8. Judges Len Goodman and Bruno Tonioli scored it a 2 and judge
Carrie Ann Inaba a 4.
To n i o l i ’s t a ke : “ I t wa s a n i g h t m a r e. ... I t l o o ke d l i ke a c h i l d o n t h e m a l l
lost looking for his mother.”
Goodman: “I know viewers think they’re being kind by bringing you back.
They’re not. They’re being cruel—to Ashly,to the judges.”
Inaba: “I actually thought that that was your best dancing.”
Master P trained only 20 hours for the show,compared to 130 for the
other contestants at that point in the season. He also refused to wear
dancing shoes and performed in basketball sneakers. The dance was
his last before being voted off.
Free download pdf