ScratchData LogoScratchData
Back to kc021's profile

Codegolf Challenge #13: To Roman Numerals

KCkc021•Created October 7, 2020
Codegolf Challenge #13: To Roman Numerals
3
3
101 views
View on Scratch

Instructions

PLEASE FULLY READ THE RULES! Sorry for all caps, I had to get your attention. Welcome to the thirteenth codegolf challenge! In this challenge, you will have to write a block that converts a number n to the shortest possible string in Roman numerals. Try to minimize your block count! Limits: n will be a positive integer. 0<n<1001 I=1 V=5 X=10 L=50 C=100 D=500 M=1000 To subtract, put a number before the following one. You may NOT use any elements of the project containing predefined data including costumes, backdrops, variables, lists, and long strings. Test cases: 1=>"I" 3=>"III" 4=>"IV" 24=>"XXIV" 501=>"DI" 999=>"CMXCIX" 1000=>"M"

Description

Have fun! I hope this isn't too hard... Entries so far:

Project Details

Project ID433569781
CreatedOctober 7, 2020
Last ModifiedJune 27, 2022
SharedOctober 7, 2020
Visibilityvisible
CommentsAllowed