Free online quizzes and exams to copy For Business and Teachers

Tour Menu

Go back to browse: Free exams and quizzes

Free Exam: Swisslog Java Programmer Exam

Number of Questions in Test: 32
Number of Questions in Preview: 5
Register to view all questions.

Note: Answers are not shown below but will be copied with this test.

Copy this test to my quiz maker account

Register with ClassMarker to copy free tests to give to your Test takers.

Register now

Question 1

OBJECT ORIENTATION

Given:

public abstract interface Frobnicate { public void twiddle(String s) ; }


Which is a correct class?

2 answers are correct.

Type: Multiple response
Points: 1
Randomize answers: No
Grade style: Full points if all answers are correct

Question 2

OBJECT ORIENTATION

Given:

1. class Plant {
2. String getName() { return "plant"; }
3. Plant getType() { return this; }
4. }
5. class Flower extends Plant {
6. // insert code here
7. }
8. class Tulip extends Flower {}


Which statement(s), inserted at line 6, will compile?

3 answers are correct.

Type: Multiple response
Points: 1
Randomize answers: No
Grade style: Full points if all answers are correct

Question 3

OBJECT ORIENTATION

Given:

1. class Zing {
2. protected Hmpf h;
3. }
4. class Woop extends Zing { }
5. class Hmpf { }

Which is true?

1 answer is correct.

Type: Multiple response
Points: 1
Randomize answers: No
Grade style: Full points if all answers are correct

Question 4

OBJECT ORIENTATION

Given:

1. class Programmer {
2. Programmer debug() { return this; }
3. }
4. class SCJP extends Programmer {
5. // insert code here
6. }

Which, inserted at line 5, will compile?

4 answers are correct.

Type: Multiple response
Points: 1
Randomize answers: No
Grade style: Full points if all answers are correct

Question 5

OBJECT ORIENTATION

Given:

1. class Dog { }
2. class Beagle extends Dog { }
3.
4. class Kennel {
5. public static void main(String [] arfs) {
6. Beagle b1 = new Beagle();
7. Dog dog1 = new Dog();
8. Dog dog2 = b1;
9. // insert code here
10. } }

Which, inserted at line 9, will compile?

2 answers are correct.

Type: Multiple response
Points: 1
Randomize answers: No
Grade style: Full points if all answers are correct

Register now for a quiz maker account to create online tests for free.

ClassMarker is a Quiz maker for teachers and businesses alike.

Did you know, with ClassMarker you can: