Yes, I've done exactly that with a 24 speed MTB, converting it to one ring at the front.
If it won't set up without a bit of rubbing at either the largest or smallest cog, don't worry as long as it engages without slipping.
As TobyAnscombe says, optimise it for your riding. Mine was set up for...