varare both upvalues to function
bin this case.
iand return the value back to us.
counter, it generates a new counter for us, it can be called any amount of times and all the counters will have different values. Each time the returned function from counter is called (the function that increments), it will only change that counter, no others.