How To Do A For Loop In Elixir (using only recursion)

No question there are better approaches. I had a novice ask me at a meetup about how to code something with recursion and I was able to answer him but I told him that I almost never use recursion in practice because there are better approaches (like Enum.each and the for comprehension). I was simply trying to provide a small, trivial example of how to emulate a for loop from an imperative language in Elixir.