0% found this document useful (0 votes)
6 views19 pages

Java Software Development MCQs PDF

Software Development MCQ PDF available on Quizplus.com. The resource URL is https://quizplus.com/study-set/1747-starting-out-with-java-from-control-structures-through-objects

Uploaded by

jh3aksg1wv
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views19 pages

Java Software Development MCQs PDF

Software Development MCQ PDF available on Quizplus.com. The resource URL is https://quizplus.com/study-set/1747-starting-out-with-java-from-control-structures-through-objects

Uploaded by

jh3aksg1wv
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Software Development MCQ PDF

[Link]
17 Chapters
953 Verified Questions
Software Development
MCQ PDF
Cou
Software Development is a comprehensive course focused on the principles,

methodologies, and tools essential for creating reliable and efficient software

applications. Students will explore the full software development lifecycle, from

requirements gathering and design to implementation, testing, and maintenance. Key

topics include programming fundamentals, software architectures, development

methodologies (such as Agile and Waterfall), version control, debugging, and

documentation. Through hands-on projects and collaborative exercises, learners gain

practical experience in working with modern programming languages and development

environments, preparing them for real-world challenges in the software industry.

Recommended Textbook
Starting Out with Java From Control Structures through Objects 6th Edition by Tony Gaddis

Available Study Resources on Quizplus


17 Chapters
953 Verified Questions
953 Flashcards
Source URL: [Link]

Page 2
Chapter 1: Introduction to Computers and Java
Available Study Resources on Quizplus for this Chatper
51 Verified Questions
51 Flashcards
Source URL: [Link]

Sample Questions
Q1) A computer program is:
A) A set of instructions that enable the computer to solve a problem or perform a task
B) Main memory
C) Pseudocode
D) A flow chart
Answer: A

Q2) The original name for Java was:


A) Java
B) HotJava
C) Elm
D) Oak
Answer: D

Q3) Syntax is:


A) Words that have a special meaning in the programming language
B) Rules that must be followed when writing a program
C) Punctuation
D) Symbols or words that perform operations
Answer: B

To view all questions and flashcards with answers, click on the resource link above.

Page 3
Chapter 2: Java Fundamentals
Available Study Resources on Quizplus for this Chatper
61 Verified Questions
61 Flashcards
Source URL: [Link]

Sample Questions
Q1) Named constants are initialized with a value, that value cannot be changed during
the execution of the program.
A)True
B)False
Answer: True

Q2) In Java, ___________ must be declared before they can be used.


A) Variables
B) Literals
C) Key words
D) Comments
Answer: A

Q3) Which of the following is a valid Java statement?


A) String str = 'John Doe';
B) string str = "John Doe";
C) string str = 'John Doe';
D) String str = "John Doe";
Answer: D

To view all questions and flashcards with answers, click on the resource link above.

Page 4
Chapter 3: Decision Structures
Available Study Resources on Quizplus for this Chatper
64 Verified Questions
64 Flashcards
Source URL: [Link]

Sample Questions
Q1) A block of code is enclosed in a set of:
A) braces { }
B) parentheses ( )
C) double quotes " "
D) brackets [ ]
Answer: A

Q2) The ________ statement is used to make simple decisions in Java.


A) do/while
B) for
C) branch
D) if
Answer: D

Q3) Because the && operator performs short-circuit evaluation, your boolean expression
will usually execute faster if the subexpression that is most likely False is on the left of the
&& operator.
A)True
B)False
Answer: True

To view all questions and flashcards with answers, click on the resource link above.

Page 5
Chapter 4: Loops and Files
Available Study Resources on Quizplus for this Chatper
57 Verified Questions
57 Flashcards
Source URL: [Link]

Sample Questions
Q1) In the following code, what values could be read into number to terminate the while
loop? Scanner keyboard = new Scanner([Link]);
[Link]("Enter a number: ");
Int number = [Link]();
While (number < 100 || number > 500)
{
[Link]("Enter another number: ");
Number = [Link]();
}
A) Numbers less than 100
B) Numbers greater than 500
C) Numbers in the range 100 - 499
D) Numbers in the range 100 - 500

Q2) Given the following statement, which statement will write "Calvin" to the file
[Link]? PrintWriter diskOut = new PrintWriter("[Link]");
A) [Link](diskOut, "Calvin");
B) [Link]("Calvin");
C) [Link]("Calvin");
D) [Link]("Calvin");

To view all questions and flashcards with answers, click on the resource link above.

Page 6
Chapter 5: Methods
Available Study Resources on Quizplus for this Chatper
60 Verified Questions
60 Flashcards
Source URL: [Link]

Sample Questions
Q1) Which of the following is NOT part of a method call?
A) method name
B) return type
C) parentheses
D) all of the above are part of a method call

Q2) What will be returned from the following method?


Public static int methodA()
{
Double a = 8.5 + 9.5;
Return a;
}
A) 18.0
B) 18 (as an integer)
C) 8.0
D) This is an error.

Q3) Only constants and variables may be passed as arguments to methods.


A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.

Page 7
Chapter 6: A First Look at Classes
Available Study Resources on Quizplus for this Chatper
58 Verified Questions
58 Flashcards
Source URL: [Link]

Sample Questions
Q1) A method that stores a value in a class's field or in some other way changes the
value of a field is known as a mutator method.
A)True
B)False

Q2) What is stored by a reference variable?


A) A binary encoded decimal
B) A memory address
C) An object
D) A string

Q3) What does the following UML diagram entry mean?


+ setHeight(h : double) : void
A) this is a public attribute named Height and is a double data type
B) this is a private method with no parameters and returns a double data type
C) this is a private attribute named Height and is a double data type
D) this is a public method with a parameter of data type double and does not return a
value

Q4) Instance methods do not have the key word static in their headers.
A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.
Page 8
Chapter 7: Arrays and the Arraylist Class
Available Study Resources on Quizplus for this Chatper
64 Verified Questions
64 Flashcards
Source URL: [Link]

Sample Questions
Q1) If numbers is a two-dimensional array, which of the following would give the length
of row r?
A) [Link]
B) [Link][r]
C) numbers[r].length[r]
D) numbers[r].length

Q2) For the following code, what would be the value of str[2]? String[] str = {"abc", "def",
"ghi", "jkl"};
A) "ghi"
B) "def"
C) A reference to the String "ghi"
D) A reference to the String "def"

Q3) Java performs ____________, which means that it does not allow a statement to
use a subscript that is outside the range of valid subscripts for the array.
A) active array sequencing
B) array bounds checking
C) scope resolution binding
D) buffer overrun protection

To view all questions and flashcards with answers, click on the resource link above.

Page 9
Chapter 8: A Second Look at Classes and Objects
Available Study Resources on Quizplus for this Chatper
50 Verified Questions
50 Flashcards
Source URL: [Link]

Sample Questions
Q1) If you attempt to perform an operation with a null reference variable:
A) the resulting operation will always be zero
B) the results will be unpredictable
C) the program will terminate
D) Java will create an object to reference the variable

Q2) If you write a toString method to display the contents of an object, object1, for a
class, Class1, then the following two statements are equivalent:
[Link](object1);
[Link]([Link]());
A)True
B)False

Q3) The this key word is the name of a reference variable that is available to all static
methods.
A)True
B)False

Q4) If a class has a method named finalize, it is called automatically just before an
instance of the class is destroyed by the garbage collector.
A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.
Page 10
Chapter 9: Text Processing and More About Wrapper

Classes
Available Study Resources on Quizplus for this Chatper
60 Verified Questions
60 Flashcards
Source URL: [Link]

Sample Questions
Q1) What does the following statement do?
Double number = new Double(8.8);
A) It creates a Double object.
B) It initializes that object to 8.8.
C) It assigns the object's address to the number variable.
D) All of the above

Q2) What is term used for a class that is "wrapped around" a primitive data type and
allows you to create objects instead of variables?
A) Intrinsic class
B) Enclosed object
C) Wrapper class
D) Transitional object

Q3) You cannot assign a value to a wrapper class object.


A)True
B)False

Q4) StringBuilder objects are immutable.


A)True
B)False

To view all questions and flashcards with Page 11 click on the resource link above.
answers,
Chapter 10: Inheritance
Available Study Resources on Quizplus for this Chatper
70 Verified Questions
70 Flashcards
Source URL: [Link]

Sample Questions
Q1) In the following statement, which is the superclass?
Public class ClassA extends ClassB implements ClassC
A) ClassA
B) ClassB
C) ClassC
D) Cannot tell

Q2) In an interface all methods have:


A) private access
B) protected access
C) public access
D) packaged access

Q3) When a subclass extends a superclass, the public members of the superclass
become public members of the subclass.
A)True
B)False

Q4) Private members of the superclass cannot be accessed by the subclass.


A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.

Page 12
Chapter 11: Exceptions and Advanced File IO
Available Study Resources on Quizplus for this Chatper
56 Verified Questions
56 Flashcards
Source URL: [Link]

Sample Questions
Q1) An exception's default error message can be retrieved using this method.
A) getMessage()
B) getErrorMessage()
C) getDefaultMessage()
D) getDefaultErrorMessage()

Q2) A class must implement the Serializable interface in order for objects of the class to
be serialized.
A)True
B)False

Q3) If, within one try statement you want to have catch clauses of the following types, in
which order should they appear in your program: (1) Exception
(2) IllegalArgumentException
(3) RuntimeException
(4) Throwable
A) 1, 2, 3, 4
B) 2, 3, 1, 4
C) 4, 1, 3, 2
D) 3, 1, 2, 4

To view all questions and flashcards with answers, click on the resource link above.

Page 13
Chapter 12: A First Look at GUI Applications
Available Study Resources on Quizplus for this Chatper
60 Verified Questions
60 Flashcards
Source URL: [Link]

Sample Questions
Q1) The following statement adds the FlowLayout manager to the container, centers the
components, and separates the components with a gap of 10 pixels.
setLayout(new FlowLayout());
A)True
B)False

Q2) Which one of the following GUI components is considered to be a container?


A) Frame
B) Label
C) Slider
D) Button

Q3) Which of the following statements creates a class that is extended from the JFrame
class?
A) JFrame DerivedClass = new JFrame();
B) class JFrame DerivedClass;
C) JFrame(DerivedClass);
D) public class DerivedClass extends JFrame{}

Q4) The FlowLayout manager does not allow the programmer to align components.
A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.
Page 14
Chapter 13: Advanced GUI Applications
Available Study Resources on Quizplus for this Chatper
58 Verified Questions
58 Flashcards
Source URL: [Link]

Sample Questions
Q1) The ImageIcon class constructor accepts:
A) an integer that references the image
B) a String argument which is the name of the image file
C) a String argument which is the name of the image
D) It does not accept any arguments.

Q2) What will be the results of executing the following code, if the user simply clicks OK?
JPanel panel = new JPanel();
Color selectedColor;
SelectedColor = [Link](null,
"Select color", [Link]);
[Link](selectedColor);
A) The foreground color will remain unchanged.
B) The foreground color will be set to white.
C) The foreground color will be set to black.
D) The foreground color will be set to blue.

Q3) When using a slider, by default, tick marks are not displayed, and setting their
spacing does not cause them to be displayed.
A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.

Page 15
Chapter 14: Applets and More
Available Study Resources on Quizplus for this Chatper
54 Verified Questions
54 Flashcards
Source URL: [Link]

Sample Questions
Q1) Which of the following will load the applet, TestApplet?
A) &lt;applet code="[Link]" width=200 height=50&gt; &lt;/applet&gt;
B) &lt;applet code=[Link] width=200 height=50&gt; &lt;/applet&gt;
C) &lt;load code="[Link]" width=200 height=50&gt; &lt;/load&gt;
D) &lt;load code=[Link] w=200 h=50&gt; &lt;/load&gt;

Q2) To support the Swing classes in applets, some browsers require a ________, which
is software that extends or enhances another program.
A) extension
B) plug-in
C) booster
D) widget

Q3) The play method will load and play a sound file once, then release it for garbage
collection. The getAudioClip method will load the sound file and may assign the location
of the sound file to a variable so it may be invoked many times.
A)True
B)False

Q4) An applet does not have to be on a Web server in order to be executed.


A)True
B)False

To view all questions and flashcards with answers, click on the resource link above.
Page 16
Chapter 15: Creating GUI Applications With Javafx and

Scene Builder
Available Study Resources on Quizplus for this Chatper
40 Verified Questions
40 Flashcards
Source URL: [Link]

Sample Questions
Q1) A window in a GUI commonly consists of several ________ that present data to the
user and/or allow interaction with the application.
A) modules
B) components
C) elements
D) buttons

Q2) Because only one RadioButton in a toggle group can be selected at any given time,
the buttons are said to be this.
A) static components
B) singularly bound
C) all inclusive
D) mutually exclusive

Q3) This is a markup language that describes the components in a JavaFX scene graph.
A) SGML
B) HTML
C) XML
D) FXML

To view all questions and flashcards with answers, click on the resource link above.

Page 17
Chapter 16: Recursion
Available Study Resources on Quizplus for this Chatper
42 Verified Questions
42 Flashcards
Source URL: [Link]

Sample Questions
Q1) Look at the following pseudocode algorithm: Algorithm Test3(int a, int b)
If (a < b)
Return 5
Else if ( a == b)
Return -5;
Else
Return (a + Test3(a - 1, b)
End Test3
What is the recursive case for the algorithm?
A) a < b
B) a == b
C) a > b
D) None of the above

Q2) Indirect recursion occurs when:


A) a loop is used to solve a recursive problem
B) a recursive method has no code to stop it from repeating
C) a method calls itself
D) a method calls itself from another method

To view all questions and flashcards with answers, click on the resource link above.

Page 18
Chapter 17: Databases
Available Study Resources on Quizplus for this Chatper
48 Verified Questions
48 Flashcards
Source URL: [Link]

Sample Questions
Q1) The data that is stored in a row is divided into:
A) sections
B) tables
C) bytes
D) columns

Q2) SQL statements that are stored in the DBMS are called resident queries.
A)True
B)False

Q3) To what package does the Connection interface belong?


A) [Link]
B) [Link]
C) [Link]
D) [Link]

Q4) The term commit refers to undoing changes to a database.


A)True
B)False

Q5) Although SQL is a language, you don't use it to write applications.


A)True
B)False

To view all questions and flashcards withPage


answers,
19 click on the resource link above.

You might also like