May I know in which of the following sentences has "there" been placed correctly?

1. What he was doing there alone at that unholy hour beats me.

2. What he was doing alone there at that unholy hour beats me
and what is the Arabic meaning ?