I’m trying to understand this example a little better

```
data Tuple a b = Tuple a b deriving (Eq, Show)
newtype Flip f a b = Flip (f b a) deriving (Eq, Show)
-- `f` is a type that has an instance `Functor` and two arguments: `a` and `b`
-- `Flip` returns the same type `f` with `a` and `b` reversed
instance Functor (Flip Tuple a) where
fmap f (Flip (Tuple x y)) = Flip $ Tuple (f x) y
aa :: Flip Tuple String Integer
aa = fmap (+1) (Flip (Tuple 1 "blah"))
-- Flip (Tuple 2 "blah")
```

What I get is:

- In
`fmap`

on the left side of`=`

,`(Tuple x y)`

get’s its`x`

and`y`

reversed. - On the right side of
`=`

`f`

is applied to`x`

and then the`Tuple`

with the new value for`x`

is flipped again.

What I don’t get is:

- I expected
`Tuple x y`

to become`Tuple y x`

- And I’m guessing it is, except that
`x`

is now`y`

and`y`

is now`x`

- But since the order
`x y`

hasn’t change I’m left wondering what has changed?

Here is my best/current guess on that is:

- Before the flip
`x`

on the LHS has the value of`a`

in the declaration line. (I’m doubting`a`

actually has a value?) - After the flip
`y`

has the value of`a`

- Therefore
`x`

is no longer part of the structure and can now be changed by applying`f`

- Then the type is flipped again to the original order.