Sams Teach Yourself C in 21 Days

(singke) #1

BONUS DAY 4


BONUS WEEK


Java Language


Fundamentals


Java was designed to avoid many of the pitfalls of C and C++, while retaining
their strengths and adding new capabilities. If you recently learned C, Java may
seem a little strange, but many programmers prefer it over all other program-
ming languages. Today, you will start your Java mini-course. You will learn


  • Basic components of a Java program

  • Java keywords and identifiers

  • Data types for numbers and strings

  • Text input and output

  • Java operators and program flow control


Structure of a Java Program ................................................................................


As you learned on Bonus Day 1, Java programs come in two types. Appletsare
small- to medium-sized programs that are designed to be distributed and used
on the World Wide Web, typically as part of a Web page. Stand alone

39 448201x-Bonus4 8/13/02 11:19 AM Page 703

Free download pdf