PBO Inheritance Episode 2

PBO Inheritance Episode 2

University

18 Qs

quiz-placeholder

Similar activities

Memahami PBO

Memahami PBO

11th Grade - University

15 Qs

II MCA ASP.NET ONLINE QUIZ

II MCA ASP.NET ONLINE QUIZ

University

15 Qs

PHP First Internal Practical Viva

PHP First Internal Practical Viva

University

20 Qs

Ulangan harian 1 Algoritma dan Pemrograman

Ulangan harian 1 Algoritma dan Pemrograman

12th Grade - University

13 Qs

Lập trình trực quan

Lập trình trực quan

University

15 Qs

Infrastructure (Network)

Infrastructure (Network)

University

20 Qs

C Quest 2.0

C Quest 2.0

University

20 Qs

PBO Inheritance Episode 2

PBO Inheritance Episode 2

Assessment

Quiz

Computers

University

Hard

Created by

Wikky Quiz

Used 68+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

18 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Perhatikan kode berikut.


class Vehicle

{

int maxSpeed = 120;

}

class Car extends Vehicle

{

int maxSpeed = 180;

void display() {

System.out.println("Maximum Speed: " + super.maxSpeed);

}

}


/* Driver program to test */

class Test

{

public static void main(String[] args)

{

Car small = new Car(); small.display();

}

}


Pada output program, berapa nilai maksimum speed yang ditampilkan?

120

180

120 dan 180

semua salah

2.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Manakah di bawah ini yang bukan konteks penggunaan keyword super dalam Java?

konstruktor

variabel

method

kelas

3.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Manakah pernyataan di bawah ini yang salah?

Method overriding harus mempunyai return type yang sama

Method yang diset private tidak bisa dilakukan overriding

Overrriding adalah salah satu bentuk run time polymorphism

Kita bisa override konstruktor sebagai parent

4.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Reusability, peningkatan fleksibilitas dan data hiding adalah manfaat dari ....

Abstraksi

Enkapsulasi

Polimorfisme

Pewarisan

5.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Keyword yang digunakan untuk inheritance adalah ...

super

extend

extends

inherit

6.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Implementation hiding sering dikenal sebagai ...

pewarisan

enkapsulasi

abstraksi data

polimorfisme

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Di bawah ini keuntungan abstraksi data kecuali ...

mengurangi kompleksitas melihat sesuatu

mencegah duplikasi kode

menurunkan reusabiity

meningkatkan keamanan

Create a free account and access millions of resources

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?