ถ้าต้องการเข้าถึงสมาชิกตัวแรกในอาร์เรย์ arr จะต้องใช้คำสั่งใด
สรุปบทเรียน การเขียนโปรแกรมเชิงวัตถุเบื้องต้น 1

Quiz
•
Computers
•
12th Grade
•
Hard
Anuwat Jaidee
Used 3+ times
FREE Resource
60 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
arr[0];
arr[1];
arr.first();
arr.begin;
2.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
คำสั่งใดใช้สำหรับประกาศอาร์เรย์ของจำนวนเต็ม
int array = new int[10];
int[] array = new int[10];
array int = new [10];
new int[10] array;
3.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
ผลลัพธ์ของโปรแกรมต่อไปนี้คืออะไร
int[] arr = {1, 2, 3, 4, 5};
System.out.println(arr[5]);
5
0
Error: ArrayIndexOutOfBoundsException
ไม่สามารถรันโปรแกรมได้
4.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
ผลลัพธ์ของโปรแกรมต่อไปนี้คืออะไร
int[] arr = {1, 2, 3, 4, 5};
System.out.println(arr.length);
4
2
3
5
5.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
คำสั่งใดใช้ในการเข้าถึงสมาชิกตัวที่ 3 ของอาร์เรย์ numbers
int[] numbers = {10, 20, 30, 40, 50};
numbers[2];
numbers[3];
numbers(2);
numbers(3);
6.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
ผลลัพธ์ของโค้ดต่อไปนี้ คืออะไร
int[][] array = { {1, 2, 3}, {4, 5, 6}, {7, 8, 9} };
System.out.println(array[1][2]);
2
4
6
8
7.
MULTIPLE CHOICE QUESTION
15 mins • 1 pt
ถ้าเราต้องการสร้างอาร์เรย์ 2 มิติขนาด 3x4 (3 แถว 4 คอลัมน์) และกำหนดค่าเริ่มต้นเป็น 0 ควรใช้คำสั่งใด
int[] array = new int[3][4];
int[][] array = new int[4][3];
int array = new int[3][4];
int[][] array = new int[3][4];
Create a free account and access millions of resources
Similar Resources on Quizizz
57 questions
ข้อสอบปลายภาค-ม.6-1-2567

Quiz
•
9th - 12th Grade
60 questions
31910-2008 การประยุกต์ AI สําหรับงานธุรกิจ

Quiz
•
9th - 12th Grade
60 questions
ข้อสอบปวช. ธุรกิจและการเป็นผู้ประกอบการ

Quiz
•
12th Grade
65 questions
แบบทดสอบระบบฐานข้อมูลชั้นสูง (B-Tech)

Quiz
•
12th Grade
59 questions
VNET 2566 แนวข้อสอบ

Quiz
•
12th Grade
60 questions
ระบบปฏิบัติการเบื้องต้น (หน่วยที่ 1-4)

Quiz
•
12th Grade
60 questions
แนวข้อสอบ 2567

Quiz
•
6th Grade - University
60 questions
รวมข้อสอบวิทยาการคำนวณปลายภาค

Quiz
•
12th Grade
Popular Resources on Quizizz
15 questions
Multiplication Facts

Quiz
•
4th Grade
25 questions
SS Combined Advisory Quiz

Quiz
•
6th - 8th Grade
40 questions
Week 4 Student In Class Practice Set

Quiz
•
9th - 12th Grade
40 questions
SOL: ILE DNA Tech, Gen, Evol 2025

Quiz
•
9th - 12th Grade
20 questions
NC Universities (R2H)

Quiz
•
9th - 12th Grade
15 questions
June Review Quiz

Quiz
•
Professional Development
20 questions
Congruent and Similar Triangles

Quiz
•
8th Grade
25 questions
Triangle Inequalities

Quiz
•
10th - 12th Grade
Discover more resources for Computers
40 questions
Week 4 Student In Class Practice Set

Quiz
•
9th - 12th Grade
40 questions
SOL: ILE DNA Tech, Gen, Evol 2025

Quiz
•
9th - 12th Grade
20 questions
NC Universities (R2H)

Quiz
•
9th - 12th Grade
25 questions
Triangle Inequalities

Quiz
•
10th - 12th Grade
65 questions
MegaQuiz v2 2025

Quiz
•
9th - 12th Grade
10 questions
GPA Lesson

Lesson
•
9th - 12th Grade
15 questions
SMART Goals

Quiz
•
8th - 12th Grade
45 questions
Week 3.5 Review: Set 1

Quiz
•
9th - 12th Grade