lizncu

1323. Maximum 69 NumberlizncuJava

Java

class Solution {
  public int maximum69Number(int num) {
    return Integer.valueOf(String.valueOf(num).replaceFirst("6", "9"));
  }
}