Advertisement
willieshi232

Unit 1 Self Check Sections 1-5

Sep 5th, 2015
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.49 KB | None | 0 0
  1. Pg.47 Answer 1-5 all pg.47- 49 Answer 6 - 16 even only pg.49-50 Answer 18 - 20 all pg.50-54 Answer 21 - 31 only odds
  2. 1.When people first started inventing computers and machines, they wanted to make it easy and simple, so they based it on binary/base 2 so circuits would be either opened or closed.
  3. 2a. 1000010
  4. 2b. 101100
  5. 2c. 1001000
  6. 2d. 10000011
  7.  
  8. 3a. 4
  9. 3b. 11
  10. 3c. 42
  11. 3d. 78
  12. 4. First- Buy cookie dough from the supermarket
  13. Second- Preheat your oven to 400 degrees f
  14. Third- Lay your pieces of cookie dough 1 inch apart from each other and put it into the oven
  15. Fourth- Wait 12 Minutes then turn your oven and take it out and let it cool.\
  16. fifth- Enjoy! or repeat steps 1-4 if you need more.
  17. 5. MyProgram.java is the program file saved, and the MyProgram.class is the Java byte code.
  18. 6.println, AnnualSalary, ABC, 42isTHeAnswer, for, B4
  19. 8. "Quotes"
  20. Slashes \//
  21. How '"confunding' "\" it is!
  22. 10: Shaq is 7'1
  23. The string "" is an empty message.
  24. \'""
  25. 12. Dear "DoubleSLash" magazine,
  26.  
  27. Your publication confuses me. Is it
  28. a \\ slash or a //// slash?
  29.  
  30. Sincerely,
  31. Susan "Suzy" Smith
  32. 14. System.out.println("This is a test of your /nknowledge of \"quotes\" used \nin 'string literals.'");
  33. System.out.println("");
  34. System.out.println("");
  35. System.out.println("You're bound to \"get it right\" \nif you read the section /n''quotes.''
  36. 16. System.out.print("Twas ");
  37. System.out.print("brillig and the")
  38. System.out.print(" ")
  39. System.out.print("\n slithy toves did");
  40. System.out.print(" ");
  41. System.out.print("gyre and");
  42. System.out.print("\ngimble");
  43. System.out.print("\n");
  44. System.out.print("\n "in the wabe");
  45. 18.
  46. 1. missing class line 1
  47. 2. Capital P line 4
  48. 3. Missing semicolon line 4
  49. 19.
  50. 1. Missing void line 2
  51. 2. S is capitalized line 2
  52. 3. Missing " line 4
  53. 4. Missing } line 5
  54. 20.
  55. 1. Missing { line 1
  56. 2. Missing args line 2
  57. 3. Missing ) line 11
  58. 4. Line 8-10 Can't comment to the right of a statement
  59. 21.b
  60. 23. Inside the first method
  61. Inside the third method
  62. Inside the first method
  63. Inside the second method
  64. Inside the first method
  65. Inside the second method
  66. Inside the first method
  67. Inside the third method
  68. Inside the first method
  69. Inside the second method
  70. 25. Inside the second method
  71. Inside the first method
  72. Inside the first method
  73. Inside the second method
  74. Inside the first method
  75. Inside the third method
  76. Inside the first method
  77. Inside the second method
  78. 27. I am method 1
  79. I am method 1
  80. I am method 1
  81. I am method 2
  82. I am method 3
  83. I am method 1
  84. I am method 2
  85. I am method 1
  86. I am method 1
  87. I am method 2
  88. I am method 3
  89. 29. 1. Space in identifier line 1
  90. 2. missing void line 2
  91. 3. Missing [] line 2
  92. 4. Missing "line 3
  93. 5. Missing semicolon line 4
  94. 6. Missing ) line 8
  95. 7. Missing } line 11
  96. 8. quotation missing \" line 9
  97. 9. quotation missing \" line 9
  98. 10. Missing " line 3
  99. 31. public class GiveAdvice
  100. {
  101. public static void main (String [] args)
  102. {
  103. System.out.println(" Programs can be easy or");
  104. System.out.println(" difficult to read, depending");
  105. System.out.println("upon their format");
  106. System.out.println()
  107. System.out.println("Everyone, including yourself,");
  108. System.out.println("will be happier if you choose");
  109. System.out.println("to format your programs.");
  110. }
  111. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement