Here’s my solution (it’s the one in the book):
And here’s the link:
http://www.lodev.org/jstumble/?board=rrerelee1rf00leelxxeerrxleelireereeleelereereelee
Description: This is a little trickier than the previous AND gate (puzzle 19) because now the bits are next to one another - it takes more than one ball to test the direction of both bits. My solution tests the state of the first bit and sends that information back to the top of the board by releasing a red ball if it points left or a blue ball if it points right.