My mom's cat does this all day. It drives us all crazy.
We put her out, she comes in, then wants back out then wants back in...wash, rinse, repeat.
Sometimes if we ignore her demands to go outside she'll go occupy herself with something else. We haven't been able to find anything that stops the constant in-out game all day.
During the summer we'll leave a window open for her so she can come and go as she pleases: outside there is a table under the window for her to land on, and inside there is a chair so she can come and go on her own more easily.
Chloe: a moody, grey ball of energy
Cooper: a black goofy ball of love