Upvote:1
Hungary is part of the Schengen area, so you'll need a Schengen visa to visit (assuming you're not already in a Schengen area country, in that case you can travel without a visa). If you intend to study there, you should apply for a student visa.
UK is outside of the Schengen zone, so your immigration status there is not relevant. However, being deported from anywhere will not improve your chances of a Schengen visa (in case UK authorities share that data with the EU or it is visible in your passport).