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

Grading app?

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?

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

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

Re: Grading app?

Thu Jul 25, 2019 1:34 am

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.

User avatar
Paeryn
Posts: 2699
Joined: Wed Nov 23, 2011 1:10 am
Location: Sheffield, England

Re: Grading app?

Thu Jul 25, 2019 4:49 am

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.

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

Re: Grading app?

Thu Jul 25, 2019 5:03 am

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

User avatar
DougieLawson
Posts: 36307
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Grading app?

Thu Jul 25, 2019 5:56 am

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

There's a bit of JavaScript I wrote 19 years ago.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

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

Re: Grading app?

Thu Jul 25, 2019 6:12 am

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.

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

Re: Grading app?

Thu Jul 25, 2019 9:19 am

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.

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

Re: Grading app?

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.
"I will go anywhere as long as it is forward" David Livingstone

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

Re: Grading app?

Thu Jul 25, 2019 10:32 am

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

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

Re: Grading app?

Thu Jul 25, 2019 2:25 pm

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.

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

Re: Grading app?

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...
"I will go anywhere as long as it is forward" David Livingstone

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

Re: Grading app?

Fri Jul 26, 2019 1:48 pm

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'?

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

Re: Grading app?

Fri Jul 26, 2019 3:23 pm

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.

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

Re: Grading app?

Sat Jul 27, 2019 11:57 am

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.
Cool.
Unix engineer since 1989

Return to “Troubleshooting”