Added a netbeans project and fixed the code to work on windows.