Anon function - not working

anon function doesn't work if called before the actual function