编辑代码

class Main {
	public static void main(String[] args) {
        //JSRUN引擎2.0,支持多达30种语言在线运行,全仿真在线交互输入输出。
		System.out.println();
	String str1="I am Tom,I am from China";
	    String str2="Tom";
	    if(str1.equals(str2))
	      System.out.println("是在一个字符串");
	      else
	      System.out.println("不在一个字符串");

    }
}