moved code into subdirectories for great justice