题解 | #小乐乐改数字#
小乐乐改数字
https://www.nowcoder.com/practice/fcd30aac9c4f4028b23919a0c649824d
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner in = new Scanner(System.in); String n=in.next(); char[] ch=n.toCharArray(); String num=""; for(int i=0;i<ch.length;i++){ num+=(int)ch[i]%2; } System.out.print(Integer.parseInt(num)); } }