Test, validate and match regular expressions
This regex parses FINA diving competition codes (e.g., 101A, 5132D, 612B) to extract individual dive properties including dive type (twisting or armstand), direction (forward/back/reverse/inward), flying indicator, number of somersaults, twists, and body position. It handles both standard codes and the more complex twisting/armstand formats with conditional logic and optional parentheses notation for twist counts.