Search Header Logo

Java OOPs - 2

Authored by ALDO STALIN J L

Computers

University

Used 54+ times

Java OOPs - 2
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

peep

bark

meow

Compilation fails

An exception is thrown at runtime.

2.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

Media Image

Cat is-a Animal

Cat is-a Jumper

Dog is-a Animal

Beagle has-a Tail

Beagle has-a Jumper

3.

MULTIPLE SELECT QUESTION

1 min • 1 pt

Media Image

public int blipvert(int x) { return 0; }

private int blipvert(int x) { return 0; }

private int blipvert(long x) { return 0; }

protected long blipvert(int x) { return 0; }

protected int blipvert(long x) { return 0; }

4.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

test

null

An exception is thrown at runtime.

Compilation fails because of an error in line 1.

Compilation fails because of an error in line 4.

5.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

Compilation fails.

An exception is thrown at runtime.

The attribute id in the Item object remains unchanged.

The attribute id in the Item object is modified to the new value.

A new Item object is created with the preferred value in the id attribute.

6.

MULTIPLE SELECT QUESTION

2 mins • 1 pt

Media Image

int foo() { /* more code here */ }

void foo() { /* more code here */ }

public void foo() { /* more code here */ }

private void foo() { /* more code here */ }

protected void foo() { /* more code here */ }

7.

MULTIPLE SELECT QUESTION

3 mins • 1 pt

Media Image

p0 = p1;

p1 = p2;

p2 = (ClassC)p4;

p2 = (ClassC)p1;

p1 = (ClassB)p3;

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?

Discover more resources for Computers