You learned how to adapt binary lifting for LCA queries. You practiced the two-phase approach: equalize depths, then binary search for the meeting point.
This technique extends to many other problems: distance queries, path queries, finding nodes at a specific distance from two sources. Binary lifting + LCA is one of the most reusable patterns in competitive programming. The distance between and is depth[u] + depth[v] - 2 * depth[LCA(u,v)].