Roman numeral

Submit

Your name:
File:
Open code-statistics:

Language is selected by the extension of the file. See the list of supported languages to know the extension of your language.

Problem

Convert the Roman numeral into the Arabic numeral.

Options

exec is denied

now post-mortem time, all source codes will be revealed

Sample input:_

III

Sample output:

3

Sample input:_

IV
XIX
LX
MDIX

Sample output:

4
19
60
1509

Sample input:_

DCCCXLII
MDCCCXXXVIII
CCI
MDCLXXIX
DLVIII
MDCCXXVI
CCII
MDLXXXIII
MCDXCII
MCCCV
MCCCXXIII
MCCXLI
CXIX
CCCLVII
MCD
CLXXV
MDCCCLXVIII
MCXIX
DCCCLXXV
MCCCLXXI
DCXLV
CMXXXIII
MCMXLVII
MCCLXII
MCMLXXI
MCXII
CCLXXXIV
MDXII
CCCLXII
DCCLXXVII
MDCXXXIII
MCDXXXIII
CCXI
MCXCIV
MCMXLVIII
CDXVIII
MCCCLXXXIII
DCCXXXV
CDLXII
MDCXCVI
DCXXVII
MDXCII
DXCII
MCCXXXIX
CCCLII
MDCCCI
XXVII
DCCCXCVII
MLXXXVII
MDCXVI
CCLXV
CCLXXIX
MCCCLXXV
MCCIV
MCLXX
DCCCLXXII
MDCCXLV
MDCCXXXVI
MDCCCXLVI
DCCX
MCCCXXXIII
MCCLXVIII
CCLXIV
CMXXXVIII
MDCLXIX
CCLIII
MDCCIV
CDX
MLXVIII
MCMLXX
MCDXCI
LII
MDCCCLXVII
DXXXVIII
MDCCCLII
MDCXXI
MCCCL
DLXXIX
MDCCCLXVI
DCCCLXXVII
MCMXLVI
CDXL
MCCXII
CMXCV
MDCCLXIX
DCCCIX
CCXXXI
CDXXV
DLXXVIII
DCCCXXIX
CCCXVIII
DCCXXXVI
CCLXXI
CXXXIII
MCCXXV
DCCXXVII
CCXLVIII
CDXCVI
MXXIX
CDLXXXVI
DCCLXXXIX
MCMLVI
MLIV
MDCCCXXII
MDCLXXV
CDXC
CCCXVI
MCCLXIII
MDXIX
CCCXC
CCCLXXIV
DCLX
MDCCXX
MDCCCLVI
MDXXXIII
DX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CLXXIX
DCVI
MCXLVII
MCDXVIII
DXLI
CCLXXXVI
MDCXCVII
DI
CCXXXV
MXVI
DCCCLXXIII
DCX
MDCXXIII
MCMXIX
MCMXX
MCCCXCIX
CDLXVIII
DCCII
CDLIX
MCDXXI
DCCCLVI
DLVI
MCXCVIII
XCVII
MXCV
MCMLXXIX
MCCCXIX
DLXII
CCXLI
DCCCXLVI
CCXXXIII
DCCXX
MLXV
MCMLXVI
MCLIX
MCMXVIII
MXXX
MCCLVIII
MCCCVI
DCCCLI
CMLXXI
CI

Sample output:

842
1838
201
1679
558
1726
202
1583
1492
1305
1323
1241
119
357
1400
175
1868
1119
875
1371
645
933
1947
1262
1971
1112
284
1512
362
777
1633
1433
211
1194
1948
418
1383
735
462
1696
627
1592
592
1239
352
1801
27
897
1087
1616
265
279
1375
1204
1170
872
1745
1736
1846
710
1333
1268
264
938
1669
253
1704
410
1068
1970
1491
52
1867
538
1852
1621
1350
579
1866
877
1946
440
1212
995
1769
809
231
425
578
829
318
736
271
133
1225
727
248
496
1029
486
789
1956
1054
1822
1675
490
316
1263
1519
390
374
660
1720
1856
1533
510
1382
1192
1825
593
1732
1927
1714
190
1570
154
1790
826
823
146
1161
448
803
1830
1301
1793
1288
1035
797
715
1828
1322
237
844
124
135
1562
1244
153
1196
700
677
1582
1903
1243
1303
1827
910
1500
1447
443
1111
1823
375
1707
223
874
1295
392
958
1294
102
1891
408
751
750
1038
838
1175
584
819
885
1033
755
1248
511
557
969
1505
1663
24
243
345
1845
1108
1685
794
1705
899
1138
1630
1641
67
1952
1693
744
1220
479
1236
1216
714
528
1061
1814
320
62
321
1098
1573
679
545
1780
1887
1279
1893
1315
1125
1761
553
1048
494
882
433
680
879
926
530
1272
323
376
1090
1772
168
144
313
1237
217
1501
1345
630
682
1339
1291
1173
74
811
116
1379
606
1147
1418
541
286
1697
501
235
1016
873
610
1623
1919
1920
1399
468
702
459
1421
856
556
1198
97
1095
1979
1319
562
241
846
233
720
1065
1966
1159
1918
1030
1258
1306
851
971
101

Ranking

Ruby _

RankUserSizeTimeDateStatistics
1eban630.05322010/07/18 02:01:030B / 38B / 24B
2murky-satyr960.09022010/07/17 01:29:450B / 47B / 41B

Perl _

RankUserSizeTimeDateStatistics
1ySas630.17612010/07/14 10:18:090B / 38B / 24B
2MG880.03542010/07/16 01:27:160B / 50B / 35B
3eban890.02582010/07/14 13:17:200B / 38B / 48B
4dcutter920.03832010/07/21 01:07:180B / 41B / 49B
5Mithran1060.05732010/07/10 12:40:360B / 67B / 38B

Python _

RankUserSizeTimeDateStatistics
1hallvabo840.07732010/07/22 03:47:180B / 51B / 22B
2betaveros1410.19262010/07/22 10:03:575B / 69B / 53B
3eyepopslikeamosquito830.11342014/04/22 18:58:112B / ?B / ?B

PHP _

RankUserSizeTimeDateStatistics
1o-cn(eyepopslikeamosquito)760.16862010/09/26 00:44:571B / 39B / 36B
2o-cn920.13362010/07/27 01:07:063B / 46B / 43B

Common LISP _

RankUserSizeTimeDateStatistics
1kozima870.40692010/07/20 08:35:570B / 47B / 36B
2quijote890.39112010/07/20 07:01:570B / 55B / 32B
3youz1480.62242010/07/23 11:54:190B / 76B / 59B
4Hawkseye5020.24022010/07/14 22:42:590B / 291B / 133B

Arc _

RankUserSizeTimeDateStatistics
1murky-satyr1236.13422010/07/13 23:12:240B / 59B / 49B

Clojure _

RankUserSizeTimeDateStatistics
1murky-satyr1435.54002010/07/13 22:57:240B / 65B / 70B

JavaScript _

RankUserSizeTimeDateStatistics
1nn1030.09892010/07/18 12:23:190B / 57B / 46B
2murky-satyr1050.06512010/07/13 23:08:400B / 53B / 50B
3murky-satyr880.07062010/07/26 07:54:400B / 51B / 35B

BASIC _

RankUserSizeTimeDateStatistics
1Carlos Gutierrez940.01072010/07/23 03:38:410B / 52B / 39B

J _

RankUserSizeTimeDateStatistics
1pooq600.17682010/07/15 23:20:320B / 24B / 34B
2I., S.550.18542012/03/25 05:57:110B / 21B / 32B

C _

RankUserSizeTimeDateStatistics
1inaniwa930.00192010/07/22 20:59:585B / 44B / 44B
2inaniwa(not original)960.01892010/07/22 16:30:200B / 53B / 43B
3hallvabo980.00242010/07/22 05:43:570B / 55B / 43B
4nu990.00182010/07/15 05:42:147B / 44B / 47B
5nai1000.00222010/07/14 02:22:293B / 49B / 48B
6nn1020.00182010/07/18 13:23:053B / 52B / 47B
7msk1210.00182010/07/23 09:48:050B / 63B / 58B
8Hawkseye1760.00182010/07/13 04:04:250B / 99B / 77B
9nu(inaniwa)900.00182010/07/24 01:22:378B / 41B / 41B
10not(inaniwa)900.00192010/07/24 10:02:248B / 41B / 41B
11inaniwa920.00172010/07/23 15:06:035B / 44B / 43B
12inaniwa(another)1100.00482010/07/23 21:12:530B / 69B / 41B

Haskell _

RankUserSizeTimeDateStatistics
1notogawa1040.00512010/07/10 16:30:480B / ?B / ?B
2rst761150.00432010/07/23 00:04:250B / 72B / 40B
3tanakh1230.02112010/07/22 23:57:140B / 67B / 51B
4Lost_dog1300.04912010/07/17 15:23:000B / 81B / 45B
5aaa1330.00512010/07/10 08:30:030B / ?B / ?B
6nobsun1410.00452010/07/10 07:02:480B / 76B / 57B

Java _

RankUserSizeTimeDateStatistics
1hallvabo1680.42622010/07/22 04:59:390B / 110B / 55B

Pascal _

RankUserSizeTimeDateStatistics
1uru3300.00322010/07/23 12:37:450B / 202B / 114B
2uru2950.00842010/07/23 19:41:200B / 199B / 74B

AWK _

RankUserSizeTimeDateStatistics
1nn1050.06142010/07/18 16:00:170B / 51B / 54B
2eban1760.00602010/07/16 19:27:410B / 84B / 89B

Bash _

RankUserSizeTimeDateStatistics
1eban1270.20192010/07/10 16:47:340B / 65B / 34B

R _

RankUserSizeTimeDateStatistics
1pooq792.24142011/08/22 14:29:490B / 50B / 26B

Vim _

RankUserSizeTimeDateStatistics
1nn1050.49452010/07/21 16:29:002B / 66B / 35B
2pla1080.69712010/07/21 00:52:0110B / 67B / 30B
3doug1120.19132010/07/21 16:39:164B / 55B / 51B
4nn1040.50432010/10/13 12:31:492B / 64B / 36B

goruby _

RankUserSizeTimeDateStatistics
1murky-satyr960.32082010/07/14 00:26:360B / 47B / 45B
2murky-satyr560.17782010/07/31 08:40:500B / 31B / 24B

Groovy _

RankUserSizeTimeDateStatistics
1nn1056.57672010/07/18 15:52:490B / 66B / 36B
2murky-satyr1146.66582010/07/12 23:29:290B / 70B / 39B
3murky-satyr796.40962010/08/22 21:42:520B / 51B / 26B

Language Ranking_

RankLangUserSizeScore
1JI., S.5510000
2gorubymurky-satyr569821
3PerlySas638730
4Rubyeban638730
5PHPo-cn(eyepopslikeamosquito)767236
6Groovymurky-satyr796962
7Rpooq796962
8Pythoneyepopslikeamosquito836626
9Common LISPkozima876321
10JavaScriptmurky-satyr886250
11Cnu(inaniwa)906111
12BASICCarlos Gutierrez945851
13Haskellnotogawa1045288
14Vimnn1045288
15AWKnn1055238
16Arcmurky-satyr1234471
17Basheban1274330
18Clojuremurky-satyr1433846
19Javahallvabo1683273
20Pascaluru2951864

return top