Search Header Logo

Review of OOPs Java Quiz1

Authored by Kundan Kumar

Computers

University

Used 1+ times

Review of OOPs Java Quiz1
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

11 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following correctly defines a class in Java?

Car class { }

class Car { }

class Car();

object Car { }

2.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is the keyword used to create an object in Java?

create

make

new

int

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

Which of the following creates an object of Student?

Student();

Student s = new Student();

Student s = new ;

Student s = Student();

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which keyword is used to inherit a class in Java?

extend

extends

inherit

superclass

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

In Java, a class can inherit from:

one class only

Multiple classes

Interfaces only

Any number of classes and interfaces

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is the correct syntax to declare a package in Java?

package myPackage;

import package myPackage;

package: myPackage;

pack myPackage;

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which statement is used to access a class from another package?

use

include

import

access

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?