Coins in the Dark

An old wizard has a pile of magic coins that he is willing to give you if you can complete a task for him. Each coin has a silver side and a gold side that are completely identical except for the color. He wants you to split the single pile into two piles where each pile has the same number of golden sides face up. Right as you are about to start on the task, the lights go out and it's too dark to tell which side is which. You do remember seeing that there were 20 coins with the gold side face-up before the lights went out.

How can you guarantee you have split the coins into two piles where each pile has the same number of coins with the gold side face-up?

...

...