如何为这样的等式编写语义树: x = y + 5
在java中:
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
System.out.println("Please Enter Your String");
String x = sc.nextLine();
for (int j = 0; j < x.length(); j++) {
char m = x.charAt(j);
System.out.println("Level "+(j+1)+" is "+m);
}
}