অণুজীব

java-language – programming-java – কুইজ মডেল টেস্ট অনুশীলন – 7

7804. Given: for(int i = 0; i < 3; i++) { switch(i) { case 0: break; case 1: System.out.print(one ); case 2: System.out.print(two ); case 3: System.out.print(three ); } } System.out.println(done); What is the result?

  1. one two three two three done
  2. one two done
  3. one two three done
  4. done

7805. Which of the following is incorrect about static variables?

  1. to 0
  2. A static variable is associated with the class as a whole rather than with specific instances of a class.
  3. nonstatic functions
  4. static class

7806. Given: interface Foo {} class Alpha implements Foo {} class Beta extends Alpha {} class Delta extends Beta { public static void main( String[] args ) { Beta x = new Beta(); // insert code here } } Which code inserted, will cause a java.lang.ClassCastException?

  1. Alphaa=x;
  2. Foo f = (Alpha)x;
  3. Beta b = (Beta)(Alpha)x;
  4. Foo f = (Delta)x;

7807. Which of these is specified by a File object?

  1. directory path
  2. directory in disk
  3. None of the mentioned
  4. a file in disk

7808. Which of these access specifiers can be used

  1. Protected
  2. private
  3. Public
  4. All of the mentioned

7809. Which of the following will produce an answer that is closest in value to a double, d, while not being greater than d?

  1. (int)Math.max(d);
  2. (int)Math.abs(d);
  3. (int)Math.min(d);
  4. (int)Math.floor(d);

7810. Which is a valid declarations of a String?

  1. String s4 = (String) ‘\ufeed’;
  2. String s3 = (String) ‘abc’;
  3. String s2 = ‘null’;
  4. String s1 = null;

7811. Which three form part of correct array declarations?

  1. public final int [ ] a
  2. All of these
  3. static int [ ] a
  4. public int a [ ]

7812. Given: public class Blip { protected int blipvert(int x) { return 0; } } class Vert extends Blip { // insert code here } Which method, inserted independently, will compile?

  1. protected long blipvert(int x) { return 0; }
  2. private int blipvert(long x) { return 0; }
  3. None of above
  4. private int blipvert(int x) { return 0; }

7813. classes are useful because they

  1. brings together all aspects of an entity in one place
  2. can closely model objects in the real world
  3. permit data to be hidden from other classes
  4. all of the above.

আমাদের কাছে থাকা লক্ষ লক্ষ মডেল টেস্ট থেকে প্রাকটিজের জন্য কিছু এখানে তুলে ধরা হল। প্রতিটি অধ্যায়ের উপরে ইশিখন.কম কুইজ চ্যালেঞ্জ এ আছে শত শত মডেল টেস্ট বার বার মডেল টেস্ট দিয়ে নিজেকে যাচাই কর এবং পুরো বাংলাদেশের সকল শিক্ষার্থীর সাথে আপনার মেধা তালিকা দেখুন। প্রশ্নে কোন প্রকার ভুল থাকলে সঠিক উত্তরসহ নিচে কমেন্ট করে জানাবেন, আমরা ঠিক করে দেবো।

Leave a Reply

স্যার, কিভাবে আপনাকে সাহায্য করতে পারি?

Click one of our representatives below

Customer Support
Customer Support

Syeda Nusrat

I am online

I am offline

Technical Support
Technical Support

Ariful Islam Aquib

I am online

I am offline