This is my code:

```
def mock(s):
    ret = ""
    i = True  
    for char in s:
        if i:
            ret += char.upper()
        else:
            ret += char.lower()
        if char != ' ':
            i = not i
    return ret
print(mock("abcd efgh ijkl"))

```

output:

```
AbCd EfGh IjKl

```

but it has to be like this:

```
AbCd eFgH IjKl

```

I don't get what i'm doing wrong and what I should do to fix it.