### valeriu's blog

By valeriu, history, 14 months ago,

Hello,

I would like to put GIFs in statements (in polygon), but attaching the GIF directly (and then inserting it like a picture) doesn't do the job. Does anybody know how to do this? please don't downvote me, I'm a very boomer

• +35

 » 14 months ago, # |   +25 Isn't attaching GIF distracting for the problem solver?
•  » » 14 months ago, # ^ |   +18 I sometimes use GIFs to explain the sample test cases. It's much easier to explain and more pleasing to the eyes (at least I hope). You can see it in action here and here
•  » » » 14 months ago, # ^ |   +7 Also here
•  » » » 14 months ago, # ^ | ← Rev. 5 →   +8 Frankly it is quite horribleIf you want to use pictures, attach them frame by frame, animated pictures look cute but are of little help.Static frame by frame illustrations would make the statements above betterI liked the illustrations in the last D problem https://codeforces.com/problemset/problem/1609/D and I appreciate that they're NOT animated
•  » » » » 14 months ago, # ^ |   +3 The example you gave doesn't really work in my opinion. It's written in the statement that each $i$ is an independent problem, so it doesn't make sense to animate them. I still think there are cases where GIFs are better but you're right. Sometimes it's better to keep the pictures frame by frame. I will consider them next time. Thanks
•  » » » » 14 months ago, # ^ |   +10 Reason I find gifs annoying : There is no way to control them and you have to wait for the loop to complete if you're looking for something.
•  » » » » 8 months ago, # ^ |   -10 It's a matter of preference. I like high-quality slow gifs more. Both approaches have pros and cons. You have to compare static illustrations manually, and it is hard to examine too many of them.
•  » » » » » 8 months ago, # ^ |   +1 I just happened look at one of those gifs after your comment and encountered the same problem as alwaysThe biggest problem is that when reading some explanation (either it is an article or a problem) I nearly always need to focus on one or two specific transitions to understand the whole picture. And animation makes it difficult. Without being able to comprehend those specific transitions, animation as a whole is useless.It maybe helpful as an addition to static pictures. However if I had to choose only one of them, I would ask to replace absolute majority of gifs here with static panes
 » 14 months ago, # |   +7 Hey boomer!
 » 14 months ago, # |   +57 Maybe you can use 1508D - Swap Pass as an example. It looks like they use this: \begin{center} \includegraphics{sample1.png} \end{center} Where sample1.png is an apng (animated png) file. You can convert gifs to apng here.
•  » » 8 months ago, # ^ |   0 when you insert the gif directly to codeforces it takes it as an image and the gif does not work, here I leave the reference to the solution for this problem #comment-627953
 » 8 months ago, # | ← Rev. 2 →   +28 [EDIT: Oops, didn't realize this was posted six months ago, but hopefully this is helpful information for anyone looking at this thread now :) ]If this is for a CF round: the last time gifs were used in problem statements, many competitors with weaker internet connections found themselves unable to load the problems. As a result, rather than embedding the gifs in the problem statement, I’d recommend hosting them on an external site and providing a link in the problem.