Multiple Choice Questions: 1.Computer programming is ---- A) an art. B) A scienc
ID: 670321 • Letter: M
Question
Multiple Choice Questions:
1.Computer programming is ---- A) an art. B) A science C) Both of the above. D) Neither of the above.
2.Another term for programs is -------A) Shareware B)Hardware C) Firmware D) Software.
3. Which of the following assignment statements is correct? (Choose all that apply) ---- A) char c = 100; B) char c = "100"; C)char c = "d"; D) char c = 'd';
4. The unicode of 'a' is 97. What is the Unicode for 'c'? ------ A) 97 B) 98 C) 96 D) 99
5. What is the printout of System.out.println('z'-'a')?------ A) a B) 25 C) 26 D) z
6. A java character is stored in ___________ A)Three Bytes B) Two Bytes C)Four Bytes D)one Byte
7. Note that the Unicode for character A is 65. The expression "A" + 1 evaluates to _____________ A) B B) A1 C) Illegal Expression D) 66
8. Which of the following are correct ways to declare variables? (choose all that applies) ________ A) int length; int width; B) int length, int width; C) int length, width; D) int length; width;
9. Which of the following assignment statements is illegal? (choose all that apply)________ A) float f = -34; B) int t = (int)false; C) int t = 4.5; D) short s = 10; e) int t =23;
10. This is a value that is written into the code of a program. A) Operator B) Assignment statement C) Variable D) Literal.
Explanation / Answer
Please find the solution...
1. Computer programming is an art.
For more inforamtion: http://www.paulgraham.com/knuth.html/
2. Another term for programs is Software.
3. Which of the following assignment statements is correct?
Ans : D) char c = 'd'
4. The unicode of 'a' is 97. What is the Unicode for 'c'?
Ans : D) 99
5. What is the printout of System.out.println('z'-'a')?
Ans : B) 25
6. A java character is stored in Two Bytes.
7. Note that the Unicode for character A is 65. The expression "A" + 1 evaluates to A1.
8. Which of the following are correct ways to declare variables?
Ans : A) int length; int width;
9. Which of the following assignment statements is illegal?
Ans : B) int t = (int)false; C) int t = 4.5;
10. This is a value that is written into the code of a program is Literal.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.