This question already has an answer here:
I have a contour vector layer with a step 0.2m . I want every 1 metre, to change the line style, a thicker line for example, and the rest of them,symbolize with a dotted style. So, I can do it manually, categorize the layer, and at each metre,change the style, or I can copy the file, paste it and delete all the Real numbers, leave the integers only, and style them as I like and put the layer over the original. My question is if I can do the same job with the "Rule-base" style. If there is a formula which can locate the integer numbers and make them a category, so I can finish my job quicker.