@@ -0,0 +1,464 @@
+def RomantoInteger(s):%0A    #enumerate Roman number in dict%0A    Roman = %7B'M':1000, 'D':500, 'C':100, 'L':50, 'X':10, 'V':5, 'I':1%7D%0A    number = 0%0A    for index in range(0, len(s) - 1):%0A        if Roman%5Bs%5Bindex%5D%5D %3C Roman%5Bs%5Bindex + 1%5D%5D:%0A            number -= Roman%5Bs%5Bindex%5D%5D%0A        else:%0A            number += Roman%5Bs%5Bindex%5D%5D%0A%0A    #add the last Roman number in the string%0A    return number + Roman%5Bs%5B-1%5D%5D%0A%0Aif __name__ == '__main__':%0A    print RomantoInteger(%22MCMX%22)%0A

Transform Roman to Integer