merged our code with Remco's and debugged