Just put some penetrating oil on it , let it soak for a while and it'll free up no problem . And if you think a little rust is reason enough to throw a bike away then don't even think you would be able to change the cogs !
The chain is easy enough, but the front chain-ring and rear sprocket(s) require special tools. If you've used the bike regularly, then the chain has probably stretched. Also check the cog teeth - if they look like a shark's fin then they are well worn.
Perhaps spend a few pounds on a bike cover next time?