Sollicitatievraag bij PayPal

1 of the questions was flip an image. a 2d array was given and we needed to flip it considering some rules.