Exam 6: Modularizing Your Code With Methods
Exam 1: Introduction to Computers and Programming161 Questions
Exam 2: Introduction to Visual C131 Questions
Exam 3: Processing Data174 Questions
Exam 4: Making Decisions77 Questions
Exam 5: Loops, Files, and Random Numbers109 Questions
Exam 6: Modularizing Your Code With Methods61 Questions
Exam 7: Arrays and Lists99 Questions
Exam 8: More About Processing Data87 Questions
Exam 9: Classes and Multiform Projects89 Questions
Exam 10: Inheritance and Polymorphism37 Questions
Exam 11: Databases69 Questions
Select questions type
Default arguments must be literals or constants.
Free
(True/False)
4.9/5
(35)
Correct Answer:
True
You can use a(n) ____________ to test a condition, and then return either to indicate whether the condition exists..
Free
(Multiple Choice)
4.8/5
(39)
Correct Answer:
B
You can pass only string arguments into string parameters.
Free
(True/False)
4.8/5
(48)
Correct Answer:
True
When you want a method to be able to change the value of a variable that is passed to it as an argument, the variable must be ____________.
(Multiple Choice)
4.8/5
(38)
When a method contains multiple parameter declarations, the declarations are often referred to as a(n) ____________.
(Multiple Choice)
4.8/5
(48)
When you call a ____________, it simply executes the statements it contains and then terminates.
(Multiple Choice)
4.8/5
(33)
A parameter variable, often simply called a(n)____________, is a special variable that receives an argument when a method is called.
(Multiple Choice)
4.8/5
(41)
Which one of the following statements correctly calls a method named ShowName?
(Multiple Choice)
4.8/5
(38)
If you are writing a method and you want it to receive arguments when it is called, you must equip the method with one or more access modifiers.
(True/False)
4.7/5
(43)
A parameter variable can be accessed by any statement outside the method in which the parameter variable is declared.
(True/False)
4.8/5
(34)
In general terms, a program that is broken into smaller units of code, such as methods, is known as a____________.
(Multiple Choice)
5.0/5
(36)
Default arguments were introduced in Visual C# 2010, so you cannot use them in older versions of C#.
(True/False)
4.9/5
(39)
When a method is declared with the private access modifier, it can be called only by code inside the same class as the method.
(True/False)
4.9/5
(45)
The contents of variables and the values of expressions can be passed as arguments to a method.
(True/False)
4.9/5
(25)
You can pass int arguments into int parameters, but you cannot pass double or decimal arguments into int parameters.
(True/False)
4.7/5
(32)
When you pass an argument to a method, the argument's data type must be ____________ with the receiving parameter's data type.
(Multiple Choice)
4.7/5
(35)
In a general sense, a class is a collection of statements that performs a specific task.
(True/False)
4.7/5
(35)
When the keyword void appears in the method header, it means that the method will return a value.
(True/False)
4.9/5
(39)
In the header, the method name is always followed by a set of parentheses.
(True/False)
4.8/5
(33)
Showing 1 - 20 of 61
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)