Example of difference between functional variable and global variable