As reported: LinkedIn Software Engineer (IC2), Infrastructure track (Bay Area, Oct 2025), virtual onsite coding round 1: Roman to Integer and Integer to Roman, then Permutations.
Given an integer num in [1, 3999], return its Roman numeral. Use the standard symbols I, V, X, L, C, D, M and the subtractive forms IV, IX, XL, XC, CD, CM; I, X, C and M repeat at most three times in a row.
This is LeetCode 12 — Integer to Roman.
Example 1
num = 58
Output: "LVIII"
Example 2
num = 1994
Output: "MCMXCIV"
Constraints: 1 ≤ num ≤ 3999.
Code runner format: LeetCode's test-case format, one JSON value per line (one line per argument). Implement intToRoman(num); the harness prints the result as JSON.