Okay, this is possible in everg game pasr G/S/C, yet it is most-probable to happen in G/S/C.
Trainer A had a fast Ditto. Trainer B has a Normal pkmn w. Encore, say Togetic. Ditto uses Transform. Togetic uses Encore. The Ditto, assuming Transform successfully works, no longer knows Transform. Probably not, but does Encore hinder the Ditto from attacking, because it no longer knows "Transform", or does it "But if failed." when Togetic uses it?
I could try this myself, but I am sure somebody here would have the answer.
Trainer A had a fast Ditto. Trainer B has a Normal pkmn w. Encore, say Togetic. Ditto uses Transform. Togetic uses Encore. The Ditto, assuming Transform successfully works, no longer knows Transform. Probably not, but does Encore hinder the Ditto from attacking, because it no longer knows "Transform", or does it "But if failed." when Togetic uses it?
I could try this myself, but I am sure somebody here would have the answer.