标签:
1 题目:
public String intToRoman(int num) { String[] M = {"","M","MM","MMM"}; String[] C = {"","C","CC","CCC","CD","D","DC","DCC","DCCC","CM"}; String[] X = {"","X","XX","XXX","XL","L","LX","LXX","LXXX","XC"}; String[] V = {"","I","II","III","IV","V","VI","VII","VIII","IX"}; return M[num/1000] + C[(num%1000)/100] + X[(num%100)/10] + V[num%10]; }
标签:
原文地址:http://www.cnblogs.com/lingtingvfengsheng/p/4567042.html