What happens next?

How to prevent a cat from spraying
Get your cat spayed or neutered.
Un-neutered male cats are the most likely culprits to engage in this very undesirable behavior. Occasionally un-spayed females will do this as well.

Possible answers:
(A). They may tell you to correct the behavior, but they might also become aggressive. Check for signs of sex at home.
(B). Therefore, it is advisable to neuter or spay your cat before the age of 6 months so as to curb this behavior from developing when puberty hits. However, a small percentage of neutered males and an even smaller percentage of spayed females will spray.
(C). Even if the cat is unneutered, spraying it repeatedly throughout the day may give off unwanted pheromones. This sends the cat's needs into action.
(D). This process is useful to prevent this behavior. Neutering your cat is the most highly recommended option if it is or is highly likely to result in the young cat spraying itself.
(B).