The seven basic symbols in a certain numeral system and their respective values are as follows:
I = 1, V = 5, X = 10, L = 50, C = 100, D = 500 and M = 1000
In general, the symbols in the numeral system are (read from left to right), starting with the symbol representing the largest value; the same symbol cannot occur continuously more than three times: the value of the numeral is the sum of the values of the symbols. For example, XXVII = 10 + 10 + 5 + 1 + 1 = 27. An exception to the left-to-right reading occurs when a symbol is’ followed immediately by a symbol of greater value; then the smaller value is subtracted from the larger.
For example, XLVI (50 — 10) + 5 + 1 = 46.
The value of the numeral MDCCLXXXVII is