[leetcode] Roman to Integer
Roman to Integer Given a roman numeral, convert it to an integer. Input is guaranteed to be within the range from 1 to 3999. tag: math, string 9/28/2015 update class Solution { public: unordered_map<char, int> map; int romanToInt(string s) { map[‘I’] = 1; map[‘V’] = 5; map[‘X’] = 10; map[‘L’] […]