Go to office hours.
I know it can sometimes be a pain to take the time out of your busy schedule to talk to your professor, but it is much needed. Your professor can tell you what you need to be focusing on and clarify confusing concepts. Ultimately, going to office hours can save you time.
Take your phone out of the picture.
Trust me, just putting it face down on the table is not enough. You really need to get it out of sight or even have a friend keep it from you. Otherwise, you will just be thinking about who's texting or snapping you the entire time.
Clear your head for a bit.
Sometimes, it can be overwhelming when you have a lot on your plate, so make sure to give yourself a second to breathe. Whether this is by taking a quick nap or going on a walk just take a little break, you deserve it. This way, when you go back to work you will have a better and more refreshed mindset.
Take care of yourself.
Make sure you establish a healthy routine for yourself. Get a certain amount of sleep, eat all of your meals, take showers etc. When you have a routine, it becomes easier to be more focused and get your work done. Remember, your health always comes first.