import java.util.Scanner; public class romannumerals{ private static int ArabicNumber = 0; public static String rom= ""; public static boolean rnum; public static String RomanNumeral(String z){ int m = z.indexOf('M'); int d = z.indexOf('D'); int c = z.indexOf('C'); int l = z.indexOf('L'); int x = z.indexOf('X'); int v = z.indexOf('V'); int i = z.indexOf('I'); if (z.contains("M")){ String firstChar = z.substring(0, m + 1); String remainingstring = z.substring(m + 1, z.length()); ArabicNumber +=1000; RomanNumeral(remainingstring); } else if (z.contains("D")){ String firstChar = z.substring(0, d +1);
Computer Sience A.P. Roman-Arabic converter (Java Project Filie)
import java.util.Scanner; public class romannumerals{ private static int ArabicNumber = 0; public static String rom= ""; public static boolean rnum; public static String RomanNumeral(String z){ int m = z.indexOf('M'); int d = z.indexOf('D'); int c = z.indexOf('C'); int l = z.indexOf('L'); int x = z.indexOf('X'); int v = z.indexOf('V'); int i = z.indexOf('I'); if (z.contains("M")){ String firstChar = z.substring(0, m + 1); String remainingstring = z.substring(m + 1, z.length()); ArabicNumber +=1000; RomanNumeral(remainingstring); } else if (z.contains("D")){ String firstChar = z.substring(0, d +1);
Need Help?
We hope your visit has been a productive one. If you're having any problems, or would like to give some feedback, we'd love to hear from you.
For general help, questions, and suggestions, try our dedicated support forums.
If you need to contact the Course-Notes.Org web experience team, please use our contact form.
Need Notes?
While we strive to provide the most comprehensive notes for as many high school textbooks as possible, there are certainly going to be some that we miss. Drop us a note and let us know which textbooks you need. Be sure to include which edition of the textbook you are using! If we see enough demand, we'll do whatever we can to get those notes up on the site for you!