Teleporting Ants & Dynamic Programming #SoME2



Codeforces Global Round 15
Problem 1552F. Telepanting
https://codeforces.com/problemset/problem/1552/F

For a challenge, can you come up with an O(N) solution?
Please leave any constructive criticism in the comments!

Submission to 3b1b’s Summer of Math Exposition 2

Written and Animated by: Henry Liu, Samuel Brashears
Produced and Narrated by: Henry Liu
Music Licensed by: APM Music | https://www.apmmusic.com/

This video was made possible by the open source library manim, created by 3blue1brown and maintained by Manim Community: https://www.manim.community/

Video Source Code: https://github.com/henryliuser/manim-cp/

27 thoughts on “Teleporting Ants & Dynamic Programming #SoME2”
  1. I've always wanted such content on youtube, and finally here it is. Looking forward for next videos.

    But personally for me it was very hard to follow the solution, the key part about what we store as dp_i and how we calculate it, is explained too briefly. (although I am 1900 on codeforces).

Leave a Reply

Your email address will not be published.