Some people make fully refundable/changeable reservations or throw away cheap fares.
Another option is holding a ticket for a bus or ferry service between points that cross a border proving your intent to leave.
BUT do not overstay your allowed time in the country.