XI LAT. SOAL 2 PSAS INF XI F
Quiz
•
Information Technology (IT)
•
9th - 12th Grade
•
Practice Problem
•
Hard
Insan Mulyana
Used 2+ times
FREE Resource
Enhance your content in a minute
50 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menjelaskan apa yang dimaksud dengan array.
Dalam C++, bagaimana cara mendeklarasikan array dengan ukuran 5?
Answer explanation
Deklarasi array yang benar di C++ adalah int arr[5] = {1, 2, 3, 4, 5};.
2.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menjelaskan cara array menyimpan sebuah nilai.
Apa yang terjadi jika Anda mencoba mengakses indeks yang lebih besar dari ukuran array?
Answer explanation
Mengakses indeks lebih besar dari ukuran array akan menyebabkan kesalahan runtime.
3.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menjelaskan bagaimana cara memberikan dan mengakses nilai sebuah array.
Untuk memberikan nilai 10 pada elemen kedua array arr[5] yang sudah dideklarasikan, pernyataan yang benar adalah...?
Answer explanation
Untuk memberi nilai pada elemen kedua array, gunakan indeks 1 (indeks dimulai dari 0).
4.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menjelaskan apa yang dimaksud dengan array multidimensi.
Bagaimana cara mendeklarasikan array dua dimensi di C++ dengan ukuran 3x3?
Answer explanation
Untuk mendeklarasikan array dua dimensi 3x3, gunakan int arr[3][3];.
5.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menggunakan array satu dimensi dalam sebuah program.
Dani ingin menghitung rata-rata dari elemen array arr[] = {2, 4, 6, 8, 10};
kode yang benar untuk menghitung rata-rata adalah...?
sum = 0; for(int i=0; i<5; i++) sum += arr[i]; avg = sum / 5;
avg = sum / 6; for(int i=0; i<5; i++) sum += arr[i];
sum = 0; for(int i=1; i<=5; i++) sum += arr[i];
sum = 0; for(int i=0; i<6; i++) sum += arr[i];
rata_rata = (2 + 4 + 6 + 8 + 10) / 5;sum = 0; avg = sum / 5;
Answer explanation
Untuk menghitung rata-rata, jumlahkan semua elemen dan bagi dengan jumlah elemen array.
6.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menggunakan array multidimensi dalam sebuah program.
Dalam array dua dimensi int arr[2][2] = {{1, 2}, {3, 4}};, bagaimana cara mengakses elemen 4?
Answer explanation
Untuk mengakses elemen 4, gunakan arr[1][1] karena elemen tersebut terletak pada indeks 1, 1.
7.
MULTIPLE CHOICE QUESTION
2 mins • 20 pts
TP. Menggunakan array dalam sebuah perulangan di dalam program.
Bagaimana cara menggunakan perulangan for untuk mencari nilai terbesar dalam array int arr[] = {3, 1, 4, 1, 5};?
Answer explanation
Menggunakan perulangan untuk membandingkan setiap elemen dan menyimpan nilai terbesar dalam variabel max.
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
50 questions
KELAS XI BAB 1 INFORMATIKA DAN PEMBELAJARANYA
Quiz
•
11th Grade - University
45 questions
PSAJ SMP ISLAM ASSALAM TAHUN 2025
Quiz
•
9th Grade
50 questions
Latihan soal-soal US SMP
Quiz
•
9th Grade - University
50 questions
Uji Pemahaman Algoritma Pemrograman
Quiz
•
10th Grade - University
50 questions
INFORMATIKA : BERPIKIR KOMPUTASIONAL
Quiz
•
10th Grade
45 questions
XII LATIHAN SOAL 1 PSAS INFORMATIKA
Quiz
•
9th - 12th Grade
50 questions
Informatika 11
Quiz
•
11th Grade
46 questions
LATIHAN SOAL ASTS 1 KELAS 9
Quiz
•
9th Grade
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
15 questions
4:3 Model Multiplication of Decimals by Whole Numbers
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
The Best Christmas Pageant Ever Chapters 1 & 2
Quiz
•
4th Grade
12 questions
Unit 4 Review Day
Quiz
•
3rd Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
Discover more resources for Information Technology (IT)
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
10 questions
Understanding Meiosis
Interactive video
•
6th - 10th Grade
26 questions
Christmas Movie Trivia
Lesson
•
8th Grade - Professio...
28 questions
Ser vs estar
Quiz
•
9th - 12th Grade
20 questions
Cell organelles and functions
Quiz
•
10th Grade
20 questions
Christmas Movie Trivia
Quiz
•
9th - 12th Grade
10 questions
Exploring the Energy Cycle: Photosynthesis and Cellular Respiration
Interactive video
•
6th - 10th Grade
25 questions
photosynthesis and cellular respiration
Quiz
•
9th Grade
