>>45
passing around the length has it's advantages. it makes the time complexity of determining the length of the list once you've filled it O(1) instead of O(n), for example.
also, for any number n, there aren't going to be more than log
2(n) prime factors.