Ответ:
1. She was buying a cake at 3 o'clock yesterday.
Was she buying a cake at 3 o'clock yesterday?
She wasn't buying a cake at 3 o'clock yesterday.
2. They were skiing when it started raining.
Were they skiing when it started raining?
They weren't skiing when it started raining.
3. The dog was sleeping while the cat was eating.
Was the dog sleeping while the cat was eating?/Was the cat eating while the dog was sleeping?
The dog wasn't sleeping while the cat was eating. / The cat wasn't eating while the dog was sleeping.