splitting into int and float versions of brute force -- int should end up being faster