看板 java 關於我們 聯絡資訊
import java.util.*; import java.io.*; class test { BufferedReader br=nuew BufferedReader(new InputStreamReader(system.in)); str=br.readLine(); StringTokenizer tokens = new StringTokenizer(str); String temp; while(tokens.hasMoreTokens()){ temp=tokens.nextToken(): if(temp=="ins") System.out.println("Find ins in the input"); else System.out.print("notFound"); } } 我想要從輸入的資料中找找看有沒有 ins這個token 但是雖然有輸入ins這樣的token 程式 跑出來的結果 卻還是notFound 已經卡了三天了 希望哪為大大可以幫我解惑 感恩 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 202.178.206.204