update examples to work on windows
Merge pull request #1275 from ethomson/examples_windows

update examples to work on windows