<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??一站式輕松地調用各大LLM模型接口,支持GPT4、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                ### **1.下面哪一個關鍵字(保留字)在Java語言中未被使用到?** >A. final >B. goto >C. enum >D. assert >答案:B ### **2.?運行完上面代碼之后輸出i的值是多少?** ``` class Happy { public static void main(String args[]) ?? ?{ ???????int i = 1 ;?? ? ???????int j = i++ ; ??????if((i==(++j))&&((i++)==j)) ?? ?{ ?????????????i += j ; ??????} ????????System.out.println("i = "+i); ??} } ``` >A. 4 >B. 5 >C. 3 >D. 6 >錯誤:B ### **3.下面哪種不是Java語言的注釋寫法?** ``` A. // 注釋 B. -- 注釋 C. /**注釋..*/ D. /* 注釋..*/ 答案:B ``` ### **4.假設有如下程序:最終的執行結果是什么?** ``` public class Demo { ????????public static void main(String args[]) { ?????????????int num = 2147483647 ; ????????????num += 2L ; ?????????????System.out.println(num) ; ?????????} } ``` >A. -2147483648 >B. 2147483649 >C. -2147483647 >D. 2 >答案:C ### **5.下面關于Java程序編寫描述正確的一項是?** >A. Java程序直接利用javac.exe命令就可以直接運行程序 >B. 一個Java文件中可以定義有多個class聲明,并且類名稱可以與文件名稱同名 >C. 一個Java文件可以使用public class定義多個程序類 >D. Java文件的后綴必須使用“*.javac” >答案:B ### **6.下面那個標識符不符合Java定義要求?** >A. String >B. _Name >C. Name123 >D. 100Book >答案:D ### **7.編譯Java源程序文件產生的字節碼文件的擴展名為?** >A. java >B. class >C. html >D. exe >答案:B ### **8.假設有如下程序:最終程序的執行結果是什么?** ``` public class Demo { ??????public static void main(String args[]) { ?????????????long num = 100 ; ?????????????int x = num + 2 ; ??????????? ?System.out.println(x) ; ????} } ``` >A. 102 >B. 1002 >C. 100 >D. 程序錯誤 >錯誤:A ### **9.假設有如下程序:最終執行結果是什么?** ``` public class Demo { ????????public static void main(String args[]) { ?????????????int x = 10 ; ?????????????double y = 20.2 ; ????????????long z = 10L; ????????????String str = "" + x + y * z ; ?????????????System.out.println(str) ; ???????} } ``` >A. 10202.0 >B. 0212.0 >C. 302.0 >D. 1020.210 >錯誤:D ### **10.現在有一個方法:**`public static int info(int x,double y)`**,下面那個方法是對本方法的正確重載?** >A. public static int infos(int x,int y); >B. public static void info(int x,double y); >C. public static int info(int x,int y); >D. public static void infos(int x,int y); >錯誤:B ### **11.假設有如下程序:最終的執行結果是什么?** ``` public class Demo { ??????public static void main(String args\[\]) { ????????????int num = 2147483647 ; ????????????num += 2 ; ???????????System.out.println(num) ; ????} } ``` >A. -2147483648 >B. 2147483649 >C. -2147483647 >D. 2 >答案:C ### **12.下面那種類型不屬于**`Java`**的基本數據類型?** >A. byte >B. int >C. boolean >D. String >答案:D 13.下面的數據聲明及賦值哪一個是正確的? >A. float f = 1.3; >B. char c = >C. byte b = 257 >D. int i = 10 >答案:D 14.假設有如下程序:最終執行結果是什么? ``` public class Demo { ??????public static void main(String args[]) { ????????????int sum = 0 ; ????????????for (int x = 0 ; x < 10 ; x ++) { ??????????????? ??sum += x ; ??????????????? ??if (x % 3 == 0) { ??????????????? ??? ???break ; ??????????????? ?} ???????????} ??????????System.out.println(sum) ; ?????} } ``` >A. 6 >B. 0 >C. 程序錯誤,死循環 >D. 45 >錯誤:C D ### **15.下面關于**`Java`**的特點不正確的一項是?** >A. Java具備跨平臺性,可以在任意的操作系統間進行移植 >B. Java編寫的程序可以直接解釋執行,屬于解釋型的編程語言類型 >C. Java中具備垃圾收集機制,這樣在用戶編寫代碼中無須處理手工處理內存空間的釋放操作 >D. Java EE企業級開發是在Java SE基礎之上的擴展應用 >錯誤:C ### **16.假設有如下程序:最終的執行結果是什么?** ``` public class Demo { ??????public static void main(String args[]) { ????????????String str = "" ; ?????????????for (int x = 0 ; x < 5 ; x ++) { ??????????????? ?str += x ; ??????????} ????????System.out.println(str) ; ?????} ?} ``` >A. 01234 >B. 10 >C. 14 >D. 25 >答案:A ### **17.假設有如下程序:最終的執行結果是什么?** ``` public class Demo { ? public static void main(String args[]) { ???????? ?int num = 2147483647 ; ?????????????long temp = num + 2L ; ????????????System.out.println(temp) ; } } ``` >A. -2147483648 >B. 2147483649 >C. 2147483647 >D. 2 >答案:B ### **18.假設有如下程序:最終執行結果是什么?** ``` public class Demo { ????public static void main(String args[]) { ????????????int sum = 0 ; ????????????int x = 10 ; ???????????while (x > 0) { ???????????sum += x ; ???????????} ???????????System.out.println(sum) ; ????} } ``` >A. 55 >B. 10 >C. 程序錯誤,死循環 >D. 15 >答案:C ### **19.**`main()`**方法的返回值類型是什么?** >A. void >B. int >C. public >D. static >答案:A 20.假設有如下程序:最終的執行結果是什么? ``` public class Demo { ?????public static void main(String args\[\]) { ????????????int num = 50 ; ???????????num = num ++ * 2 ; ???????????System.out.println(num) ; ???} } ``` >A. 50 >B. 102 >C. 100 >D. 101 >錯誤:B
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看