Firstly, You go to My Stuff.
Then, you go to +New Project.
After that, you drag the when flag clicked bar.
Then, you go to the Looks section and drag the next costume bar, underneath the when flag clicked bar.
Now, when you click the flag, it will start animating. If you want to keep that happening forever, you go to the Control section and drag the forever bar underneath the when flag clicked.
If you only want to make it go for a specific amount of times you have to go to the control section and drag the repeat bar, underneath the when flag clicked bar.
The forever bar and repeat bar will automatically stretch, to the end of your code, unless if you put something under it. If you want to make a time difference between both costumes you can go to the control bar and get the wait 1 seconds bar.