[Java] (Learning Memo) Java Level 2 Measures: Scope of Questions

1 minute read

Self-learning notes TBE

Question range

*Including the level 3 questions

  • Answer questions and answers with Java SE 8.


Operators are symbols used in arithmetic and mathematics, such as + (plus), -(minus), = (equal), etc. It’s a sequel.

① Bit operator (&, ^, |, ~)
② Shift operator («, », »>)

Shift each bit of target value right or left

③ Assignment operator (&=, ^=, |=, «=, »=, »>=)

Operator to use when assigning numbers or characters to variables

④ instanceof operator

An operator for dynamically determining the type of an object · Whether the object is an instance of a class

  • Whether the object is an instance of a child class of a certain class
  • Whether the object is an instance that implements a specific interface

⑤ Diamond operator For example List a = new ArrayList(); List a = new ArrayList<>(); Can be written abbreviated as

Control statement

Added in Java 8 Writing a program in lambda format reduces the amount of code and makes it easier to read

Classes and inheritance

Class qualifier (default), public, final, abstract What is inheritance? extends Type conversion (cast) this and super Interface implements

Variables and methods

Variable and method modifiers (when omitted), public, protected, private, final, static

What is an override?

Redefine the method defined in the parent class in the child class Override occurs in two or more classes with inheritance relationship

What is overload?

Defining methods with the same name in the same class The names are the same, but the number of arguments, the type of arguments, and the sort order are defined differently.


Up to Java SE 6: “Generic name” Java SE7 or later: “Generics”

Collection class

  • “List”, “Set” and “Map” are prepared as interfaces
  • When actually using, use a class that implements these interfaces ・Often used is an ArrayList of List ・List・・・Interface
  • ArrayList…-It is a class that implements List.
  • A collection class is a class that implements the collection framework interface, such as ArrayList.


Package and classpath Class path Package definition package Use of package import

Exception handling

Exception definition Exception handling try~catch?finally throw throws


What is a thread Thread creation