Please see Kurt Pfeifle's answer here for a corrected version of this hasty answer. Hopefully, I've somewhat redeemed myself in the followup question
To answer your question more directly, it's difficult to explain what the code does because it isn't complete.
The start of both snippets is 2 copy
which pushes duplicates of the top two things on the stack. What are these things? ??!
Well, they're probably numbers. In the first example, they're almost definitely a coordinate pair: x and y. If y is greater than 2, then draw a line to (current-x + y-from-stack, 0). Why do this? ??!
In the second example, KochR
is most likely a recursive procedure to draw a Koch curve where one of the parameters is almost certainly the recursion level, and the other is probably the length of a single line-segment (unless it's really sophisticated and offers a global-scaling control).
That's about all that can be guessed from the code as shown. HTH.