kata using discriminated union instead of an enum