In scientific computing I often want to run loops indefinitely when looking for a possible counterexample, such as repeat{ if(counterexample)break }
. I also want to use parallel::mclapply to take advantage of multiple cores. Is there a way to do this? I would rather not create a huge vector e.g., mclapply(1:1e9, ...)
for memory reasons and anyway it isn’t really an endless loop.