Question: what is the difference between stateless or stateful in salesforce?
Answer: Using Stateful Batch Apex. Batch Apex is stateless by default. That means for each execution of your execute method, you receive a fresh copy of your object. All fields of the class are initialized, static and instance.