new prog for collatz