Here's the answer:
“nous avons dormi dans le train parce que nous n'avions pas d'argent pour un h?tel”
Watch a real native speaker say it:
Here's how it sounds in a textbook:
Fun fact: the hundreds of thousands of people learning French with Memrise get this phrase correct 93.27% of the time!