The number 317942 (three hundred seventeen thousand nine hundred forty-two) is written in Roman numerals as follows: CCCXVIICMXLII