OOPS doubts

 What is instance ?
Class as a blueprint or a template that defines the structure and behavior of objects, while an instance is an actual object that is created and exists in memory based on that blueprint.

Method vs Function

function: A function can accept input and return output, and it can be utilized in any part of the program.

method: A method is similar to a function, but it is associated with a specific object or class.

What is Constructor and its uses?
It is called when an object is created using the new keyword. Constructors are used to set initial values or perform any necessary setup tasks before using the object.

void main() {
  FirstClass f1 = new FirstClass('shreyash', 'kolhe');
  f1.PrintName();
}

class FirstClass {
  late String
      fName; //late is used to declare a variable or field that will be initialized at a later time.
  late String lName;

  FirstClass(String fName, String lName) {
    print('constructor call');
    this.fName = fName;
    this.lName = lName;
  }

  void PrintName() {
    print('fName: ' + fName + " " + "lName: " + lName);
  }
}
constructor call
fName: shreyash lName: kolhe
Before calling method constructor called and initialise first and last name then method called.
Uses
1. Constructor help to create object of class.
2. How an object should be created and what initial values it should have.
class Quote {
  String? text;
  String? author;

  Quote({required this.text, required this.author});
}

class Temp {
  Quote quote = Quote(
    text: 'Be yourself; everyone else is already taken',
    author: 'Oscar Wilde',
  );

  void printQuote() {
    print("quote: ${quote.text} by ${quote.author}");
  }
}

void main() {
  Temp temp = Temp();
  temp.printQuote();
}
quote: Be yourself; everyone else is already taken by Oscar Wilde
Compile Time error Vs Run time Error
if you run program first it goes to compile process and convert to machine readable format and then run the programe.
Compile time error : when error occur during compilation time. i.e syntax error
Runtime error : error occur during execution of program. 

Final keyword?
The final keyword is used to declare a variable whose value cannot be changed.

Difference between const and final?
Both are used to declare variables that cannot be reassigned once they are initialized. final is used for variables that can have a single assignment and be initialized at runtime, while const is used for variables that must have a value known and computable at compile-time, restricted to compile-time constant values.

What happen if we put const before constructor in dart?
That means you are indicating that the object created using that constructor should be a compile-time constant. It enables you to create objects that are known at compile-time rather than at runtime.