public int romanToInt(String s) {
        if(s == null || s.equals("") == true)
            return 0;
        
        int current_level = 0, sum = 0;
        int length = s.length();
        for(int i=length-1;i>=0;i--)
        {
            int item = hs.get(s.charAt(i));
            if(current_level <= item)
            {
                current_level = item;
                sum += item;
            }
            else
                sum -= item;
        }
        return sum;
    }