To add onto what Eric was saying, lerp is just a math function that returns a value based on the three inputs. Here’s an example, this will return 2.5…
Debug.Log(Mathf.Lerp(0, 5, 0.5));
Because you’re doing a linear interpolation between 0 and 5 halfway between the numbers.
Debug.Log(Mathf.Lerp(0, 5, 1.0));
This returns 5, because you’re interpolating all the way between the two numbers.
The reason it’s used for animation is because you can do this…
transform.position = Vector3.Lerp(start.position, end.position, Time.deltaTime);
If you put this in an Update() function, this will move the object between the start position and end position.
The problem with Lerp is in cases like this…
transform.position = Vector3.Lerp(transform.position, end.position, Time.deltaTime);
Notice the difference? Instead of using a fixed transform for the starting position, we’re using the position of the object being Lerped. This means that when the object is far away, it will move much faster towards the end position, and when it gets closer, it will greatly slow down.
Hope I’ve been making this clear, I know I had a bit of trouble with lerps when I first started out, just want to make it a bit easier for you.