Faulty for declaration and  missing semicolon fixed