Sep 20, 2024
public class Main {
public static void main(String[] args) {
System.out.println("Hello, World!");
}
}
public class Main
System.out.println()
is used to print to the console.type variableName;
int age;
int age = 27;
+=
, -=
, etc. (e.g., number += 5;
)returnType methodName(parameters) { /* code */ }
int[] numbers = new int[5];
numbers[0]
).numbers.length
Arrays.sort()
and Arrays.binarySearch()
.ArrayList<Type>
for resizable arrays.add()
, remove()
, clear()
, size()
, contains()
, get()
, set()
.HashMap<KeyType, ValueType>
.put()
, get()
, remove()
, containsKey()
, containsValue()
, size()
, clear()
.