Sains Komputer Tingkatan 5 - 3.1.8 Penggunaan Tatasusunan

Quiz
•
Computers
•
1st - 12th Grade
•
Medium
Mohd Nasaruddin
Used 47+ times
FREE Resource
5 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Penggunaan adalah untuk menyimpan satu senarai nilai dalam satu pemboleh ubah
2.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Nilai awalan semasa pengisytiharan:
var no = [5,-1,4,12,8];
Berdasarkan sintaks di atas, apakah nilai bagi no[0]?
3.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Berikut adalah sintaks untuk mendapatkan nombor dalam senarai satu per satu dan menjumlahkannya.
<html>
<body>
<script>
var no = [5, -1, 4, 12, 8];
var jumlah = 0;
jumlah = no[0] + no[1] + no[2] + no[3] + no[4];
document.write (jumlah);
</script>
</body>
</html>
Berdasarkan aturcara di atas, berapakah nilai output bagi jumlah?
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Berikut adalah sintaks untuk menggunakan ulangan untuk mendapatkan nombor dalam senarai dan menjumlahkannya.
<html>
<body>
<script>
var no = [5, -1, 4, 12, 8];
var jumlah = 0;
var i;
for (i=0; i<5; i++)
{
jumlah = jumlah + no[i];
}
document.write (jumlah);
</script>
</body>
</html>
Berdasarkan aturcara di atas, berapakah nilai output bagi jumlah?
5.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Berikut adalah atur cara untuk mencari nilai daripada suatu senarai nombor dalam tatasusunan..
<html>
<body>
<script>
var no = [5, -1, 4, 12, 8];
var i;
for(i=0; i<5; i++)
{
if (no[i] == 5)
document.write (no[i]);
}
</script>
</body>
</html>
Berdasarkan aturcara di atas, berapakah nilai outputnya?
Similar Resources on Wayground
10 questions
HTML Tags

Quiz
•
9th Grade
10 questions
JavaScript ievads

Quiz
•
7th - 8th Grade
10 questions
PHP Basic

Quiz
•
11th Grade
10 questions
TLE Q3 QUIZ MODULES 1-5

Quiz
•
10th Grade
10 questions
Programación Visual

Quiz
•
12th Grade
10 questions
Introduction to PHP: Hypertext Preprocessor

Quiz
•
11th - 12th Grade
10 questions
Java Script

Quiz
•
10th - 12th Grade
10 questions
Evaluación 1erParcial M3S2.

Quiz
•
6th Grade
Popular Resources on Wayground
15 questions
Hersheys' Travels Quiz (AM)

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade
Discover more resources for Computers
15 questions
Hersheys' Travels Quiz (AM)

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade