To make the choice even better, go with the M2 Pro Mac Mini & an iPad Pro. With the iPad Pro, you can use all of the Microsoft Suite apps (including OneNote) for school and you can draw or handwrite notes on it (whereas you can’t with the MacBook Pro).
And use the M2 Pro Mac Mini at home for more powerful projects
With the cloud, everything you do on the iPad will transfer over to the Mac immediately.
And Boom! Now you can have 2 devices for the price of one
You can have even better portability, and still have a powerful desktop setup
If you absolutely require M2 Pro / Max power & portability, then this doesn’t apply to you, lol. But I’m sure that’s a small minority of the customers anyway