Are function scope and block scope are same Code Example
are function scope and block scope are same
Function Scope: When a variable is declared inside a function, it is only accessible within that function and cannot be used outside that function
Block Scope: A variable when declared inside the if or switch conditions or inside for or while loops, are accessible within that particular condition or loop