السبت، 11 أبريل 2009

حلول كتاب جافا الاصدار الرابع

Exercises

Included below are short-answer and programming exercises. Answers are provided for those exercises whose exercise number is a hyperlink. Because college faculty use these exercises in their exams, we have provided answers to roughly half of the exercises included here.


1.4 Categorize each of the following items as either hardware or software:

  1. CPU
  2. Java compiler
  3. ALU
  4. Java interpreter
  5. input unit
  6. an editor program

1.5 Why might you want to write a program in a machine-independent language instead of a machine-dependent language? Why might a machine-dependent language be more appropriate for writing certain types of programs?

1.6 Fill in the blanks in each of the following statements:

  1. Which logical unit of the computer receives information from outside the computer for use by the computer ____________?
  2. The process of instructing the computer to solve specific problems is called ___________.
  3. What type of computer language uses English-like abbreviations for machine language instructions? ___________.
  4. Which logical unit of the computer sends information that has already been processed by the computer to various devices so that the information may be used outside the computer? ________________.
  5. Which logical unit of the computer retains information? ________________.
  6. Which logical unit of the computer performs calculations? _______________.
  7. Which logical unit of the computer makes logical decisions? ______________.
  8. The level of computer language most convenient to the programmer for writing programs quickly and easily is ________________.
  9. The only language that a computer can directly understand is called that computer's ________________.
  10. Which logical unit of the computer coordinates the activities of all the other logical units? ______________.

1.7 Distinguish between the terms fatal error and nonfatal error. Why might you prefer to experience a fatal error rather than a nonfatal error?

1.8 Fill in the blanks in each of the following statements (based on Sections 1.12 and 1.15):

  1. Java ______________ are designed to be transported over the Internet and executed in World Wide Web browsers.
  2. ________________ programming causes a program to perform a task in response to user interactions with graphical user interface (GUI) components.
  3. Java’s graphics capabilities are _______________ and hence, portable.
  4. The standard _________________ can be used to provide identical user interfaces across all computer platforms.
  5. Languages that cannot perform multiple activities in parallel are called ______________ languages or __________________ languages.
  6. Aggregations of data such as linked lists, stacks, queues and trees are called ____________________.


Selected Answers

Included below are answers to approximately half the of the exercises in the Cyber Classroom. We are not able to include answers to every exercise because college faculty use these exercises in their classroom exams.


1.4 Categorize each of the following items as either hardware or software:

  1. CPU
    ANS: hardware
  2. Java compiler
    ANS: software
  3. ALU
    ANS: hardware
  4. Java interpreter
    ANS: software
  5. input unit
    ANS: hardware
  6. an editor program
    ANS: software

1.8 Fill in the blanks in each of the following statements (based on Sections 1.12 and 1.15):

  1. Java are designed to be transported over the Internet and executed in World Wide Web browsers.
    ANS: applets.
  2. programming causes a program to perform a task in response to user interactions with graphical user interface (GUI) components.
    ANS: Event-driven.
  3. Java?s graphics capabilities are and hence, portable.
    ANS: platform independent.
  4. The standard can be used to provide identical user interfaces across all computer platforms.
    ANS: Java look-and-feel
  5. Languages that cannot perform multiple activities in parallel are called languages or languages.
    ANS: sequential programming, single-thread-of-control.
  6. Aggregations of data such as linked lists, stacks, queues and trees are called .
    ANS: data structures.

ليست هناك تعليقات:

إرسال تعليق