From an Islamic point of view, one has to pray within the time window of each prayer (which is not necessarily from adhan to adhan):
فَإِذَا قَضَيْتُمُ الصَّلَاةَ فَاذْكُرُوا اللَّهَ قِيَامًا وَقُعُودًا وَعَلَىٰ جُنُوبِكُمْ فَإِذَا اطْمَأْنَنتُمْ فَأَقِيمُوا الصَّلَاةَ إِنَّ الصَّلَاةَ كَانَتْ عَلَى الْمُؤْمِنِينَ كِتَابًا مَّوْقُوتًا
And when you have completed the prayer, remember Allah standing, sitting, or [lying] on your sides. But when you become secure, re-establish [regular] prayer. Indeed, prayer has been decreed upon the believers a decree of specified times.
— Surat An-Nisa' 4:103
In Sahih Muslim, Abu Amr Shaibani narrated that Abdullah asked the Messenger of Allah (prayers and blessings be upon him) about which of the deeds are liked most by Allah, and he replied:
عَنْ عَبْدِ اللَّهِ عَنِ النَّبِيِّ صلى الله عليه وسلم قَالَ: أَفْضَلُ الأَعْمَالِ - أَوِ الْعَمَلِ - الصَّلاَةُ لِوَقْتِهَا وَبِرُّ الْوَالِدَيْنِ
It is reported on the authority of 'Abdullah that the Messenger of Allah observed: "The best of' the deeds or deed is the (observance of) prayer at its proper time and kindness to the parents."
— Sahih Muslim, Book 1, Hadith 162
From a legal point of view, to address your specific situation, you are in my opinion limiting your options to either praying before the time of the prayers (not acceptable), after the time of the prayer (not a sound recommendation as it has a number of conditions for it to be a proper solution) or to pray in class. How about excusing yourself out of a classroom during the time of the prayers and praying in some place where there is no distraction?
Praying in school is legal, long as it is on a voluntary basis and carried on in a non-disruptive way.
As you live in the US, by law, schools are not allowed to initiate religious activities, but teachers and students are permitted to pray at any time of day, as long as they do it privately and refrain from forcing others to join them. In 1995, President Bill Clinton issued a memo titled "Religious Expression in Public Schools," that said in part:
It seems that some school officials, teachers, and parents have assumed that religious expression of any type is either inappropriate or forbidden altogether, in public schools. As our courts have reaffirmed, however, nothing in the First Amendment converts our public schools into religion-free zones or requires all religious expression to be left behind at the schoolhouse door. While the government may not use schools to coerce the consciences of our students or to convey official endorsement of religion, the government's schools also may not discriminate against private religious expression during the school day.
Not only that but you can also ask for a prayers room. In 2009, Liberty High's Principal, Scott Warstler, noticed then that Muslim students were leaving school for Friday prayers, and "missing about two hours of class because of the commute." He let them use an empty classroom as a prayer room. The Frisco Independent School District said it did not violate any state or federal laws by having a prayer room, and that the room is open to students of all faiths. You may refer to High school 'Muslim prayer room' challenged and Prayer rooms are one way public schools accommodate students and freedom of religion for further debates on the topic.