A ship that was carrying 2 crates with a total of 4000 watermelons crashed into a rock. After a few hours one of the crates, together with 5 of the ship's sailors, stranded on a little island. On this island they found nothing but 1 monkey.
During the night sailor 1 woke up and took a look at the crate full of watermelons. He divided them fairly over himself and his 4 buddies. However, when he was done dividing them, he noticed that there was 1 watermelon leftover. He gave that one to the monkey. After that he hid his part somewhere on the island put the other watermelons back in the crate.
One hour later, sailor 2 woke up. He followed the same approach as sailor one, except he could only divide the watermelons that sailor 1 had left behind. He too noticed that there was 1 watermelon leftover and he gave it to the monkey.
Sailor 3, 4 and 5 did exactly the same.
The next morning when they all wake up they see that there are still some watermelons in the crate. However this time it is possible to divide the watermelons over the 5 sailors without giving one to the monkey.
How many watermelons were in the crate?