Leetcode, Roman To Integer, Scala, Programming, Algorithms.
with respective values of 1, 5, 10, 50, 100, 500, and 1000. Given a roman numeral, the task is to convert it to an integer. Function Signature in Scala: object Solution { def romanToInt(s: String): Int = { } } Examples: Input: s = “III”, Output: 3 Input: s = “LVIII”, Output: 58 Input: s =