You may want to first solve the puzzle by conventional means, but here is how the algorithm works. The puzzle squares are numbered left to right starting with 0. Moves are designated by the number of the square from which the move is made. At any particular stage of the puzzle, only two moves are possible. All chromosomes have the same length which I chose to be 5 genes longer than necessary.
Crossover is an operator that for a pair of chromosomes produces two other chromosomes.
The population of ten chromosomes is sorted according to their fitness. The mating chromosomes are selected randomly with probabilities proportional to their fitness. The algorithm usually finds one of the two solutions in less than 1000 iterations. It requires only little ingenuity to carry out the algorithm for a small puzzle manually. Watching the algorithm work, one can easily gain appreciation of the difficulty involved in solving a problem like this.