You have a row of 8 coins. You can flip coins over with certain moves, by either:
A.) Flipping over three consecutive coins OR
B.) Flipping over two consecutive coins where one is heads and the other tails.
1.) With the first four coins starting on heads and the second four starting on tails, switch the layout to all heads in four moves.
2.) With all coins starting on heads, switch to all tails in five moves.