adding test,got rid of tail calls so I could debug stuff.  added a bunch of extra print statments.