The number 39887 (thirty-nine thousand eight hundred eighty-seven) is written in Roman numerals as follows: XXXIXDCCCLXXXVII