Learn Apex
Variables & data types
Apex is statically typed: every variable has a type. Primitives and sObjects cover most automation — pick the type that matches your data.
Types

Integer

Whole numbers — watch overflow on big math.

Defaults / nulls: null for object fields; locals must be assigned

Snippet
Integer i = 0;
i += Trigger.new.size();
Collections (recap)
List<String> names = new List<String>();
Set<Id> ids = new Set<Id>();
Map<Id, Account> m = new Map<Id, Account>();