His saying: {Ask permission and greet their inhabitants} means: until you seek permission; according to the interpretation of Qatadah. There is a transposition (taqdim wa ta'khir) in the verse: until you greet [and ask permission].