A PHP developer shares a trick for vertically aligning Roman numeral arrays in code. The issue is that Unicode Roman Numeral characters are not monospaced, making it impossible to align the array operators neatly. The solution is to flip the array — using integers as keys and Roman numeral strings as values, then calling array_flip() — so the numeric keys align perfectly in columns.
Sort: