Complete explanation with examples