code: function fromRoman( str )
  	 {
  		 str = str.toUpperCase();
  		 var l = romans.length, retVal = 0;
  		 for ( var i = 0; i < l; ++i )
  		 {
  			 for ( var j = romans[i], k = j[1].length; str.substr( 0, k ) == j[1]; str = str.substr( k ) )
  				 retVal += j[ 0 ];
  		 }
  		 return retVal;
  	 }
docs: Convert roman numbering back to decimal.