AaronRPI
Posts: 30
Joined: Thu May 02, 2019 11:32 am

Hello, how do i create an app/program that will put a Roman numeral after a number like this

100= ll
99=llll
98=l

Is there any way to do this with libreoffice excel?

All help is appreciated.
"I will go anywhere as long as it is forward" David Livingstone

W. H. Heydt
Posts: 13345
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

One can certainly write a program that takes a decimal value in a puts Roman Numerals out. The conversion is pretty simple. I would not that your examples are not actually equalities, though.

100 --> C
99 --> LXXXXVIIII, or LXLIX, or some other possibilities
98 --> LXLVIII

Not sure where the values you show came from or what they're supposed to be.

Paeryn
Posts: 3054
Joined: Wed Nov 23, 2011 1:10 am
Location: Sheffield, England

W. H. Heydt wrote:
Thu Jul 25, 2019 1:34 am
100 --> C
99 --> LXXXXVIIII, or LXLIX, or some other possibilities
98 --> LXLVIII
Your 90s aren't standard, general rules are

I can only prefix V and X (1 before 5 or 10),
X can only prefix L and C (10 before 50 or 100),
C can only prefix D and M (100 before 500 or 1000).
V, L & D (5, 50 & 500) can't be repeated, only I, X, C & M (1, 10, 100 & 1000).
You shouldn't have more than three letters repeated (too easy to misread four consecutive identical letters as three).

So 90 shouldn't be written as LXXXX (50 + 10 + 10 + 10 + 10) or LXL (50 + 10 before 50), it should be XC (10 before 100).

98 --> XCVIII
99 --> XCIX
She who travels light — forgot something.

Michiel O.
Posts: 178
Joined: Mon Dec 12, 2016 12:06 pm

Just out of curiosity, what does the 'grading' mean?
"You can't actually make computers run faster, you can only make them do less." - RiderOfGiraffes

DougieLawson
Posts: 39871
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK

https://javascriptsource.com/roman-numerals/

There's a bit of JavaScript I wrote 19 years ago.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

All fake doctors are on my foes list.

W. H. Heydt
Posts: 13345
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

DougieLawson wrote:
Thu Jul 25, 2019 5:56 am
https://javascriptsource.com/roman-numerals/

There's a bit of JavaScript I wrote 19 years ago.
It's probably been done in every programming language ever used.

scruss
Posts: 3407
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

AaronRPI wrote:
Thu Jul 25, 2019 12:47 am
Hello, how do i create an app/program that will put a Roman numeral after a number like this

100= ll
99=llll
98=l

Is there any way to do this with libreoffice excel?
LibreOffice Calc has a ROMAN(Number; Mode) function. I don't understand your grading schema, but this works:

Code: Select all

``````N	ROMAN(N,4)
100	C
99	IC
98	VCIII
…
``````
… as far as Roman numerals could ever be said to ‘work’. Toothpaste For Dinner's new numbers make about as much sense.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

AaronRPI
Posts: 30
Joined: Thu May 02, 2019 11:32 am

Sorry for my stupidity, I ment tally marks. Also I would like the code in java. I mean grading so I can compare scores easier. I want to be able to type a number like 98 and the computer puts a tally mark after that number, so I have more typing and less mousing.
"I will go anywhere as long as it is forward" David Livingstone

scotty101
Posts: 4063
Joined: Fri Jun 08, 2012 6:03 pm

AaronRPI wrote:
Thu Jul 25, 2019 10:08 am
Sorry for my stupidity, I ment tally marks. Also I would like the code in java. I mean grading so I can compare scores easier. I want to be able to type a number like 98 and the computer puts a tally mark after that number, so I have more typing and less mousing.
If you want it to work with libreoffice, you would be better using the libreoffice macros than Java.
https://documentation.libreoffice.org/a ... acros.html

Do you want a number like 99 to have 99 tally marks? Or what do you want? It isn't clear what the pattern is from your examples.
Electronic and Computer Engineer
Pi Interests: Home Automation, IOT, Python and Tkinter

scruss
Posts: 3407
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Unicode has fence/tally marks for two numbers, 1 and 5:

Code: Select all

``````1D377	 𝍷 	Tally Mark One
1D378	 𝍸 	Tally Mark Five
``````
You'll need to do the integer division and modulus bit to find out how many of each glyph you'll need
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

AaronRPI
Posts: 30
Joined: Thu May 02, 2019 11:32 am

I want the app to put one tally mark beside each number each time I type that number, and I would like the tally mark on ONLY the number i type in.

I'm not sure how to put it any other way...
"I will go anywhere as long as it is forward" David Livingstone

PhatFil
Posts: 1703
Joined: Thu Apr 13, 2017 3:55 pm
Location: Oxford UK

AaronRPI wrote:
Fri Jul 26, 2019 1:18 pm
I want the app to put one tally mark beside each number each time I type that number, and I would like the tally mark on ONLY the number i type in.

I'm not sure how to put it any other way...
how about specifying the range of all possible scores and each tally mark you want associated with each number. or is the actual tally mark irrelevant and you just want a token visual tally mark to show next to the score you just/last changed or to indicate which score is being edited/'in focus'?

scruss
Posts: 3407
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Something like this as you enter them?

Code: Select all

``````Student         Mark    Tally
Ainsley         83	I		← 83 seen for the first time
...

Student         Mark    Tally
Ainsley         83
Babcock         86	I		← 86 seen for the first time
...

Student         Mark    Tally
Ainsley         83
Babcock         86
Bland           83	II		← 83 seen again
...

Student         Mark    Tally
Ainsley         83
Babcock         86
Bland           83
Carthorse       85	I		← 85 seen for the first time
...

Student         Mark    Tally
Ainsley         83
Babcock         86
Bland           83
Carthorse       85
Dint            83	III		← 83 seen for the third time
``````
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

cpc464
Posts: 238
Joined: Tue Jul 08, 2014 5:10 pm
Contact: Website