There are 3 ways to walk from B to B in two steps:
Each individual path has probability , for , and where is the probability of going from vertex to vertex (which is also the entry of the transition matrix computed in the previous question). The total probability of starting at B and ending at B after two steps is the sum
which is the (2,2) entry of the transition matrix squared.