_______ access specifier is used with main method. Select one: a.public     b.private     c.default     d.None of these   State if it is True or False: User-defined exceptions are possible. Select one: a.TRUE     b.FALSE     c.May be     d.None of these   _____ is used to declare a package in java. Select one: a.pkg     b.pkge     c.package     d.None of these

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

_______ access specifier is used with main method.

Select one:

a.public

 

 

b.private

 

 

c.default

 

 

d.None of these

 

State if it is True or False: User-defined exceptions are possible.

Select one:

a.TRUE

 

 

b.FALSE

 

 

c.May be

 

 

d.None of these

 

_____ is used to declare a package in java.

Select one:

a.pkg

 

 

b.pkge

 

 

c.package

 

 

d.None of these

_______ is the most restricted access specifier.

Select one:

a.public

 

 

b.private

 

 

c.default

 

 

d.None of these

 

State if it is True or False: Throw and Throws are used for different functions.

Select one:

a.TRUE

 

 

b.FALSE

 

 

c.May be

 

 

d.None of these

 

"Package statement must be the first line in a java program." This statement is:

Select one:

a.TRUE

 

 

b.FALSE

 

 

c.May be True

 

 

d.None of these

 

 

____is an error which occurs during run-time.

Select one:

a.Compile-time error

 

 

b.Exception

 

 

c.Link Error

 

 

d.None of these

Interface and abstract class have ______ in common.

Select one:

a.Abstract methods

 

 

b.Non-abstract methods

 

 

c.Both A and B

 

 

d.None of these

 

Name of the package must be the same as that of the _____ in java.

Select one:

a.folder

 

 

b.all parent folders separated by dots

 

 

c.all parent packages separated by dots

 

 

d.All of these

 

 

Multiple inheritance is possible with ________ in java.

Select one:

a.Class

 

 

b.Interface

 

 

c.Abstract class

 

 

d.All of these

 

All Interface variables are ___ by default in Java.

Select one:

a.public

 

 

b.abstract

 

 

c.both a &B

 

 

d.None of these

 

An interface in java is like a 100%________.

Select one:

a.Class

 

 

b.Abstract class

 

 

c.final class

 

 

d.None of these

 

 

State True or False: final and finally both are used in exception handling mechanism.

Select one:

a.TRUE

 

 

b.FALSE

 

 

c.May be True

 

 

d.None of these

 

 

Exception class exist in ___________.

Select one:

a.java.util

 

 

b.java.lang

 

 

c.java.net

 

 

d.All of these

 

 

A Java interface is not considered a class.

Select one:

a.TRUE

 

 

b.FALSE

 

 

c.May be

 

 

d.Can't say

 

 

What happen in case of multiple catch blocks?

Select one:

a.Either super or subclass can be caught first.

 

 

b.The superclass exception cannot caught first.

 

 

c.The superclass exception must be caught first.

 

 

d.None of these

 

 

 

 

Which keyword specifies the exception thrown by a method?

Select one:

a.throw

 

 

b.throws

 

 

c.finally

 

 

d.final

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps

Blurred answer
Knowledge Booster
Exception Handling Keywords
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education