local variable referenced before assignment

example ceng application