Tìm kiếm:
TRANG NHÀ
Giới thiệu VNEDU.ORG
Điều khoản và bản quyền
Liên lạc VNEDU
TRẮC NGHIỆM TRỰC TUYẾN
---Công Cụ:---
Soạn Biểu thức
Bảng màu HTML
Ký hiệu đặc biệt 01
Ký hiệu đặc biệt 02
Ký hiệu đặc biệt 03
Ký hiệu đặc biệt 04
Ký hiệu đặc biệt 05
Ký hiệu đặc biệt 06
Ký hiệu đặc biệt 07
Ký hiệu đặc biệt [Toán]
Tin Học   ||  Căn Bản    Văn Phòng    Hệ Thống - Mạng    Phần Mềm Ứng Dụng    Kỹ thuật số    Lập trình    SQL  

Trắc Nghiệm Java - Bài 55
Ngày làm bài: Hôm nay lúc 15:54:48 (Server time)
Số câu hỏi: 10.   Tổng điểm: 10
Yêu cầu hoàn thành: 60 phút.
Thời gian còn lại: 
Cỡ chữ câu hỏi:  Cỡ chữ đáp án:


1-
You need to store elements in a collection that guarantees that no duplicates are stored. Which one of the following interfaces provide that capability?
  A - 
Java.util.Map
  B - 
Java.util.List
  C - 
Java.util.Collection
  D - 
None of the above
2-
Which collection class allows you to access its elements by associating a key with an element's value, and provides synchronization?
  A - 
java.util.SortedMap
  B - 
java.util.TreeMap
  C - 
java.util.TreeSet
  D - 
java.util.Hashtable
3-
What is the numerical range of char?
  A - 
0 to 32767
  B - 
0 to 65535
  C - 
-256 to 255
  D - 
-32768 to 32767
4-
Which of the following are true statements?
  1. The Iterator interface declares only three methods: hasNext, next and remove.
  2. The ListIterator interface extends both the List and Iterator interfaces.
  3. The ListIterator interface provides forward and backward iteration capabilities.
  4. The ListIterator interface provides the ability to modify the List during iteration.
  5. The ListIterator interface provides the ability to determine its position in the List.
  A - 
2, 3, 4 and 5
  B - 
1, 3, 4 and 5
  C - 
3, 4 and 5
  D - 
1, 2 and 3
5-
Which method must be defined by a class implementing the java.lang.Runnable interface?
  A - 
void run()
  B - 
public void run()
  C - 
public void start()
  D - 
void run(int priority)
6-
Which two statements are true?
  1. Deadlock will not occur if wait()/notify() is used
  2. A thread will resume execution as soon as its sleep duration expires.
  3. Synchronization can prevent two objects from being accessed by the same thread.
  4. The wait() method is overloaded to accept a duration.
  5. The notify() method is overloaded to accept a duration.
  6. Both wait() and notify() must be called from a synchronized context.
  A - 
1 and 2
  B - 
3 and 5
  C - 
4 and 6
  D - 
1 and 3
7-
Which of the following statements is true?
  A - 
If assertions are compiled into a source file, and if no flags are included at runtime, assertions will execute by default.
  B - 
As of Java version 1.4, assertion statements are compiled by default.
  C - 
With the proper use of runtime arguments, it is possible to instruct the VM to disable assertions for a certain class, and to enable assertions for a certain package, at the same time.
  D - 
When evaluating command-line arguments, the VM gives -ea flags precedence over -da flags.
8-
What will be the output of the program?
try 
{
    Float f1 = new Float("3.0");
    int x = f1.intValue();
    byte b = f1.byteValue();
    double d = f1.doubleValue();
    System.out.println(x + b + d);
}
catch (NumberFormatException e) 
{
    System.out.println("bad number");
}

  A - 
9.0
  B - 
bad number
  C - 
Compilation fails on line 13.
  D - 
Compilation fails on line 14.
9-
What will be the output of the program?
public class ExamQuestion6 
{
    static int x; 
    boolean catch()
    {
        x++; 
        return true; 
    } 
    public static void main(String[] args)
    {
        x=0; 
        if ((catch() | catch()) || catch()) 
            x++; 
        System.out.println(x); 
    } 
}

  A - 
1
  B - 
2
  C - 
3
  D - 
Compilation Fails
10-
What will be the output of the program?
String s = "hello"; 
Object o = s; 
if( o.equals(s) )
{
    System.out.println("A"); 
} 
else
{
    System.out.println("B"); 
} 
if( s.equals(o) )
{
    System.out.println("C"); 
} 
else
{ 
    System.out.println("D"); 
}
  1. A
  2. B
  3. C
  4. D
  A - 
1 and 3
  B - 
2 and 4
  C - 
3 and 4
  D - 
1 and 2
 
[Người đăng: Thành Lãm - ST]
Ghé thăm Kênh của Vị Sư "hai lần chết đi sống lại"
Tu Si Chau Soc Thon

https://www.youtube.com/channel/UCoyC9WTTVR-M3qpTKKEXGnQ

Chau Soc Thon Official Channel


Phong Bảo Official
Phong Bao Official
Xem Nhiều nhất
Trắc Nghiệm Pascal - Bài 20
Trắc Nghiệm ASP.NET - Bài 12
Trắc Nghiệm Ngôn Ngữ Lập Trình C - Bài 16
Trắc Nghiệm ASP.NET - Bài 01
Trắc Nghiệm ASP.NET - Bài 03
Trắc nghiệm C++ - Bài 18
Trắc Nghiệm C# - Bài 53
Trắc Nghiệm ASP.NET - Bài 02
Trắc Nghiệm C# - Bài 42
Trắc Nghiệm Java - Bài 01
Trắc Nghiệm ASP.NET - Bài 04
Trắc Nghiệm Pascal - Bài 22
Trắc Nghiệm ASP.NET - Bài 13
Trắc Nghiệm ASP.NET - Bài 09
Trắc Nghiệm ASP.NET - Bài 08
Trắc nghiệm PHP - Bài 01
Trắc Nghiệm ASP.NET - Bài 06
Trắc Nghiệm ASP.NET - Bài 11
Trắc Nghiệm ASP.NET - Bài 05
Trắc Nghiệm ASP.NET - Bài 23
Đề Xuất
Trắc Nghiệm Ngôn Ngữ Lập Trình C ( English ) - Bài 19
Trắc Nghiệm C# - Bài 48
Trắc Nghiệm ASP.NET - Bài 11
Trắc Nghiệm ASP.NET - Bài 19
Trắc nghiệm Ngôn Ngữ Lập Trình C++ - Bài 53
Trắc Nghiệm ASP.NET (English) - Bài 30
Trắc Nghiệm Thiết Kế Web Và Flash - Bài 12
Trắc Nghiệm Visual Basic - Bài 35
Trắc Nghiệm Ngôn Ngữ Lập Trình C ( English ) - Bài 70
Trắc Nghiệm ASP.NET (English) - Bài 18
Trắc Nghiệm ASP.NET (English) - Bài 17
Trắc Nghiệm ASP.NET (English) - Bài 09
Trắc Nghiệm Visual Basic - Bài 38
Trắc Nghiệm Thiết Kế Web (English) - Bài 36
Trắc nghiệm Linux - Bài 59
Trắc Nghiệm Ngôn Ngữ Lập Trình C - Bài 23
Trắc Nghiệm Thiết Kế Web - Bài 10
Trắc Nghiệm Visual Basic - Bài 28
Trắc nghiệm XML - Bài 14
Trắc Nghiệm Visual Foxpro - Bài 09
Phát triển hệ thống: TRƯƠNG HỮU ĐỨC - Phiên bản 3.0 - © Copyright 2013 - 2024 - VNEDU.ORG

free counters