• Card 28 / 37: class Type { public Object getTypeName(){ return "Type"; } } class SubType extends Type { public String getTypeName(){//line 8 return "SubType"; } } public class Tester { public static void main(String[] args) { Type first = new SubType(); //line 16 System.out.println(first.getTypeName()); //line 17 } } What modification is necessary to produce the following output : SubType
    A) At line 8 change ´the return type from String to Object to be a correct
    B) overloading of getTypeName()
    C) No modification is needed
    D) At line 16 change Type to SubType
    E) At line 17 cast first.getTypeName() to String

    Answer:
    C) No modification is needed

  • Keyboard Shortcuts

    Previous Card ← Previous Card Button
    Next Card → Next Card Button
    Flip Card Space-Bar
<< First < Previous Next > Last >>

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now
Hide Choices Interactive Question Quiz Home Page
https://www.jobilize.com/ocjp-1z0-803-oca1-7-mock-exam-quiz-by-pankaj-kalra

OCA(1z0-803_OCA1.7)MockExamPI

Author:

Access: Public Instant Grading

Flash Cards plugin by Curtis Blackwell github.com/curtisblackwell/flash_cards
Google Play and the Google Play logo are trademarks of Google Inc.
Ask
David Bourgeois
Start Quiz
Miranda Reising
Start Quiz
Copy and paste the following HTML code into your website or blog.
<iframe src="https://www.jobilize.com/embed/ocjp-1z0-803-oca1-7-mock-exam-quiz-by-pankaj-kalra" width="600" height="600" frameborder="0" marginwidth="0" marginheight="0" scrolling="yes" style="border:1px solid #CCC; border-width:1px 1px 0; margin-bottom:5px" allowfullscreen webkitallowfullscreen mozallowfullscreen> </iframe>