Software Development MC

2015-07-07 4:35 am
Can u help me to answer these MC questions? please ensure that all of them are correct, and briefly explain why it is correct, thanks.
1. Which of the followings cannot be used as a Java comment?

a. < hi >
b. /** hi */
c. /* hi */
d. // Hi

2. In drawing a flowchart, which of the following symbols represent an input/output process?

a. A parallelogram
b. A rectangle
c. An Oval
d. An arrow

3. Which of the followings is the appropriate command used for the compilation of a Java programme called “myfirst.java”?

a. java myfirst
b. javac myfirst
c. javac myfirst.java
d. compile myfirst

4. Which of the following descriptions about "Algorithm" is wrong?

a. The ideas of an algorithm could be presented by using pseudo-codes or flowcharts.
b. Bytecode is an example of algorithms.
c. An algorithm is a sequence of unambiguous instructions for solving a specific task.
d. Algorithms are often used in mathematics and problem solving.

5. Which of the following data types requires the most amount of memory in computer?

a. bye
b. long
c. int
d. short

回答 (1)

2015-07-07 10:42 pm
✔ 最佳答案
1. a
< hi > is not supported. The Java language supports three kinds of comments:
/* hi */
/** hi */
// hi

2. a, b
In flowchart symbols, a parallelogram represents input or output; a rectangle represents a process; an oval represents a start or end point; an arrow is a connector which shows relationships between the representative shapes.

3. c
The command ro run the Java compiler javac.exe is:
C:\mywork> javac myfirst.java
After compilation, you should see nothing but the next system prompt.

4. b
Bytecode, also known as p-code (portable code), is a form of instruction set designed for efficient execution by a software interpreter. It is not an example of algorithm. Unlike human-readable source code, bytecodes are compact numeric codes, constants, and references (normally numeric addresses) which encode the result of parsing and semantic analysis of things like type, scope, and nesting depths of program objects.

5. b
The four integer types ‘byte’, ‘long’, ‘int’, ‘short’ have widths of 8-bit, 64-bit, 32-bit, and 16-bit correspondingly. Thus the ‘long’ integer type of 64-bit consumes the most amount of memory.


收錄日期: 2021-04-11 21:12:20
原文連結 [永久失效]:
https://hk.answers.yahoo.com/question/index?qid=20150706000051KK00077

檢視 Wayback Machine 備份