精華區beta java 關於我們 聯絡資訊
※ 引述《smilehack.bbs@bbs.kimo.com.tw (Allen)》之銘言: > class test { > public static void main(String args[]) { > byte ascii[] = {65,66,67,68,69,70}; > String s1 = new String(ascii,0); > System.out.println(s1); > String s2 = new String(ascii,0,2,3); > System.out.println(s2); > } > } > 我寫了這程式~~但編譯出來有問題 > c:\javac test.java > Note: test.java uses or overrides a deprecated API. > Note: Recompile with -deprecation for details. > 請問以上是什麼問題,謝謝 叫你用 javac -deprecation test.java 重新 compile 一遍 它會告訴你,你用了哪幾個已經被廢除的 API 你必須要用新的 API 來替換它們. -- ┌─────KKCITY─────┐  ̄ ▌ ̄ ╲╱ BBS 城邦 bbs.kkcity.com.tw ╴ ▌ ▌ ▏ KK免費撥接 └──From:140.118.7.213 ──┘ 電話:449-1999 帳號:kkcity 密碼:kkcity