Can I always write the 艹 (grass radical) with three lines only?
Two notes:


艹 is 4 strokes in Taiwan and Hong Kong only. It is less helpful to think of it as a "traditional"/"simplified" difference, as among other standards which use "traditional characters" (e.g. Korean Hanja), it is also 3 strokes.
歡 does not strictly contain 艹; it is historically written with 卝, commonly known as 羊頭. In modern times, the distinction may be relaxed, and many fonts may display it with 艹. Please refer to this Quora answer detailing what kinds of characters contain 卝 rather than 艹.


To "write things correctly", you need to understand what kind of regional Han character standard you're adhering to and look up the character in their official list. Otherwise, you should stick to the most recent common ancestor of all Han character standards, which is the Kangxi Dictionary standard.