Where a 301 says a move is permanent, a 302 says it's temporary: the page at this URL will come back, this is just a detour for now. It's the right code for a page under maintenance, an A/B test sending a portion of traffic to a variant, or a seasonal redirect that needs to revert once the season ends.
Visitors can't tell a 302 from a 301 just by using the site; both send the browser to another page transparently. Search engines can tell the difference, though, and treat them differently: a 302 is meant to keep the original URL as the one indexed, since search engines expect it to come back into use, while a 301 hands that role to the destination. Using a 302 for a change that's actually permanent is a common mistake, since it can leave the old URL indexed and diluted with ranking signals long after the new page should have taken over entirely.

