[MASCHINE Learning] Linear Regression with One Variable

package samples.string.japanese; public class ZenkakuAlphabetToHankakuAlphabet { public static String zenkakuAlphabetToHankaku(String s) { StringBuffer sb = new StringBuffer(s); for (int i = 0; i < sb.length(); i++) { char c = sb.charAt(i); if (c >= 'a' && c <= 'z') { sb.setCharAt(i, (char) (c - 'a' + 'a')); } else if (c >= 'A' && c <= 'Z') { sb.setCharAt(i, (char) (c - 'A' + 'A')); } } return sb.toString(); } public static void main(String[] args) { System.out.println (zenkakuAlphabetToHankaku ("☆ Java programming ☆")); } }screencapture-coursera-org-learn-machine-learning-exam-QeJ50-linear-regression-with-one-variable-1485179272026.png

Recommended Posts

[MASCHINE Learning] Linear Regression with One Variable
[Rails] Learning with Rails tutorial