C# 考试选择题
- 提问者网友:战魂
- 2021-08-10 14:26
Error 1 occurs when you introduce typing errors into your program.
Error 2 occurs when the program halts unexpectedly during execution.
Error 3 occurs when the program works correctly but produces incorrect results.
These three errors (Error 1, Error 2, Error 3) can be described as:
A. Runtime, Logical, Syntax
B. Logical, Syntax, Runtime
C. Syntax, Logical, Runtime
D. Logical, Runtime, Syntax
E. Syntax, Runtime, Logical
12. What do programmers use to translate their high-level language statements into machine
code?
A. A debugger
B. A translator
C. A compiler
D. An IDE
E. A spooler
13. Which of the following terms refers to the rules of a programming language?
A. Syntax
B. Logic
C. Variable
D. Procedures
E. Reserved rules
14. Which of the following statements below represents a cast?
A. int value;
B. int value = 7;
C. int value = int.Parse(“7”);
D. int value = (int) myValue;
E. int value = tempStr.ToString();
15 Which of the following statements is true about the following declaration?
int myAge = 25;
A. This is a legal statement in C#.
B. This is an illegal declaration because it uses the comparison operator instead of the
assignment operator.
C. This is an illegal declaration because assignment operators work from right to left.
D. This is an illegal declaration because it is missing the const modifier.
E. This is an illegal declaration because it initializes a variable.
- 五星知识达人网友:上分大魔王
- 2021-08-10 15:20
11. Consider the following statements about software errors:
Error 1 occurs when you introduce typing errors into your program.
Error 2 occurs when the program halts unexpectedly during execution.
Error 3 occurs when the program works correctly but produces incorrect results.
These three errors (Error 1, Error 2, Error 3) can be described as:
A. Runtime, Logical, Syntax
B. Logical, Syntax, Runtime
C. Syntax, Logical, Runtime
D. Logical, Runtime, Syntax
E. Syntax, Runtime, Logical
12. What do programmers use to translate their high-level language statements into machine
code?
A. A debugger
B. A translator
C. A compiler
D. An IDE
E. A spooler
13. Which of the following terms refers to the rules of a programming language?
A. Syntax
B. Logic
C. Variable
D. Procedures
E. Reserved rules
14. Which of the following statements below represents a cast?
A. int value;
B. int value = 7;
C. int value = int.Parse(“7”);
D. int value = (int) myValue;
E. int value = tempStr.ToString();
15 Which of the following statements is true about the following declaration?
int myAge = 25;
A. This is a legal statement in C#.
B. This is an illegal declaration because it uses the comparison operator instead of the
assignment operator.
C. This is an illegal declaration because assignment operators work from right to left.
D. This is an illegal declaration because it is missing the const modifier.
E. This is an illegal declaration because it initializes a variable.