CHAPTER 3 - 10. JOptionPane.ShowMessageDialog(null,...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Jeremy Debruce Tuesday, September 25, 2007 Professor Cambell Computer Science Chapter Three Exercises 1. a) False, b)True, c)True, d) True 2. Primitive- stores data directly in their own memory space. Reference- store the address of the object containing data 3. object- instantiating an object of that class 4. instantiate an object of that class type and store the address of the object into the reference variable 5. Str = new String( " Java Programming") 6. a) 0, b) 10, c) open, d) 't', e) "park" 7. a) Going b) amusement c) GOING TO THE AMUSEMEMENT PARK d) going to the amusement park e) Going *o*he amusement park 8. a) show InputDialog b) show MessageDialog c) scanner d) javax.swing 9. a pop up box appears an allows the user to input the score
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 10. JOptionPane.ShowMessageDialog(null, prog_out) 11. JOptionPane.ShowMessageDialog(null, "current Temperature: 70" "Temperature", JOptionPane.QUESTION_MESSAGE); 12.a) b) c) d) 13. x = console.nextInt(); Ch = console.nextInt().charAt (0); y = console.nextInt(); 14. 15. a) same as before b) the file contains the output produced by the program c) the file contains the output produced by the program. Old contents are erased d) the program would prepare the file and store the output in the file Chapter Three Programming Exercises 1 a) Scanner infile = new Scanner( new FileReader)) import java.util.*; import java.io.*;...
View Full Document

Page1 / 2

CHAPTER 3 - 10. JOptionPane.ShowMessageDialog(null,...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online