Advice for focusing during a breakup :(

Currently the week before finals and I'm struggling so hard to focus when I study. The break up was a few weeks ago but I feel like things havent gotten better. It feels the hardest when I'm alone with my thoughts (ie studying). I just keep thinking of my ex and all the things I want to say to her. Any advice for locking in or just redirecting your brain?