First learn what recursion is. You can go that by learning what recursion is.
Recursion is like a loop, but it's different.
If you think about classic exam,ples of recursion, there is factorial:
N! = N * (N - 1)! while N > 1
That's obviously recursive, because the definition of a factorial value is expressed in terms of a factorial of a lesser value (until you run out of values)
So the first big step in implementing a recursive function in any language to to express the operation in terms of a recursive algorithm. I.e. express "N even numbers" as recursive pseudo code. Then you can start implementing it.
Give it a try: this isn't complicated, but it's something you need to get your head around for yourself - being given a solution doesn't teach you anything about how to do it next time!