Fixes #2, _posOf and _numAt functions, combined res and primes in primesUpTo

* Issue #2 should now be fixed. Some extra work may be needed with the
logic (e.g. lines 63-68) but at least it works. Essentially the issue
was partly due to indentation in lines 38-39 and partly due to working
out primes above sqrt(x) when they were already passed in primes
* Private _posOf and _numAt functions to calculate position of number
in lst and number position in lst refers to
* Got rid of res in primesUpTo - using primes (parameter) instead as
they are essentially the same thing and this should save some memory