got mostly working, but after 1 iteration through perfect number checking, it stops checking