the global variable has a global scope and life time of the whole program..while
a static variable has a local scope(can't be used outside the scope) but life time of the whole program( its value...