I'm new to Stata and am not too familiar with statistical software. I'm trying to construct some different variables. I have OCC, which is a 3-digit Census occupation code. This variables ranges from 3-889. I need to break down the OCC into five different categories. The first category is managerial and professional workers and the OCC code for this is 3-199. Each other category is similar in that they all have a set range of numbers. I'm just not sure what the code is to generate each variable from a range of the OCC.

Thanks for the help