O GoConqr está de visual novo! Conte para nós o que você achou.

Quiz

Chapter 1: Quiz

Ed Woo 25 perguntas Atualizado em 23 nov 2016

Fazer o quiz

Perguntas do quiz (25)

  1. 1 In the following code, identify which line is redundant.

    1. import java.lang.String;
    2. import java.lang.*;
    3. public class Foo {
    4. String name;
    5. }
    1. A4
    2. B1
    3. C2
    4. D3
  2. 2Which of the following import statements imports an entire group of classes contained in the java.lang package?
    1. Aimport *.java.lang
    2. Bimport *.java.lang;
    3. Cimport java.lang.*
    4. Dimport java.lang.*;
  3. 3Which path does the Java runtime environment use for searching?
    1. AClass path
    2. BFile Path
    3. CEnvironment path
    4. DSearch path
  4. 4Which of the following will create a package named My?
    1. Apackage My[];
    2. Bpackage My;
    3. Cpack My();
    4. Dpackage My package;
  5. 5Consider the given string:

    Mack John Lisa Maria


    What is the output of the following Java statement?

    System.out.println(args[2]);
    1. ALisa
    2. BMaria
    3. CMack
    4. DJohn
  6. 6For any non-null reference values a and b, which of the following values will be returned by the expression a.equals(b) if b.equals(a) returns true?
    1. Atrue
    2. Bfalse
    3. Cnull
    4. D0
  7. 7In the following code, you need to import the two classes FileInputStream and FileOutputStream.

    public class CopyFile {
    String name;
    }


    What is the best way to import these files?
    1. Aimport java.FileInput Stream;
      import java.FileOutput Stream;
    2. Bimport java.nio.*;
    3. Cimport java.*.*;
    4. Dimport java.io.FileInputStream.*;
      import java.io.FileOutputStream.*;
  8. 8Which two keywords are used for decimal-point value?
    1. Ashort and long
    2. Bfloat and double
    3. Cfloat and long
    4. Dlong and double
  9. 9What is the default initialization value of long variable type?
    1. Afalse
    2. B0
    3. C0.0
    4. Dnull
  10. 10Which of the following represents the correct sequence of these three in a Java application?

    1. package declaration
    2. class definition
    3. import statement
    1. A1, 2, 3
    2. B3, 2, 1
    3. C1, 3, 2
    4. D2, 3, 1

Informações

Descrição
Java I Quiz sobre Chapter 1: Quiz, criado por Ed Woo em 26-07-2016.
Autor
Ed Woo
Idioma
English
Visualizações
0
Histórico
Criado em 26 jul 2016 · atualizado em 23 nov 2016
Etiquetas
java i
Avaliação
Ainda sem avaliações
Avalie este quiz
Avalie este quiz

Fale Conosco

Sobre o que é sua mensagem?

O que você acha do novo visual?

Você gostou?