Update RomanToInteger.java
In case if lower case roman letters are supplied, we need to convert into single case(Upper case).
This commit is contained in:
parent
5fd352f84e
commit
eb75ce5096
@ -29,6 +29,7 @@ public class RomanToInteger {
|
|||||||
*/
|
*/
|
||||||
public static int romanToInt(String A) {
|
public static int romanToInt(String A) {
|
||||||
|
|
||||||
|
A = A.toUpperCase();
|
||||||
char prev = ' ';
|
char prev = ' ';
|
||||||
|
|
||||||
int sum = 0;
|
int sum = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user