Apa yang terjadi ketika Anda menggunakan operator & di Go?
GO! Quizz Zeriusz Day 9

Quiz
•
Information Technology (IT)
•
10th Grade
•
Hard
PO Bootcamp
Used 1+ times
FREE Resource
8 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Mengakses nilai dari pointer
Membuat salinan dari nilai
Mendapatkan alamat memori dari variabel
Menghapus data di memori
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Di Go, bagaimana cara mendefinisikan sebuah struct?
struct MyStruct { int a; int b; }
class MyStruct { int a; int b; }
type MyStruct struct { a int; b int }
MyStruct -> struct { a int; b int }
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Apa perbedaan antara pointer dan reference di Go?
Pointer menunjuk ke alamat memori, reference menunjuk ke objek langsung
Pointer digunakan untuk array, reference digunakan untuk map
Tidak ada reference di Go, hanya ada pointer
Reference lebih cepat daripada pointer di Go
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Bagaimana cara mendeklarasikan method untuk struct di Go?
func (self MyStruct) MyMethod() {}
method MyStruct.MyMethod() {}
def MyStruct.MyMethod(self) {}
func MyStruct.Method(self) {}
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Apa yang akan terjadi jika Anda mengubah nilai melalui pointer di Go?
Nilai asli dari variabel yang ditunjuk akan berubah
Nilai pointer akan berubah
Tidak ada yang berubah
. Pointer akan dihapus dari memor
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Apa perbedaan utama antara method dan fungsi biasa di Go?
Method bisa dipanggil tanpa objek, fungsi biasa tidak
Method memiliki receiver yang menunjukkan objek yang dioperasikan
Method hanya bisa digunakan dengan pointer
Tidak ada perbedaan
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Bagaimana cara membuat pointer ke struct di Go?
ptr := &MyStruct{}
ptr := MyStruct{}
ptr := &struct(MyStruct)
ptr := new MyStruct
8.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Di Go, apa nama receiver yang umum digunakan untuk method dalam struct?
this
self
it
Nama singkatan dari struct, seperti s atau t
Similar Resources on Quizizz
10 questions
Kiến thức cơ bản về Python

Quiz
•
10th Grade
7 questions
C++ Structuri repetitive

Quiz
•
8th Grade - University
10 questions
Soal Evaluasi TIK (Perangkat Keras)

Quiz
•
9th - 12th Grade
10 questions
Tes pemahaman awal

Quiz
•
9th - 12th Grade
10 questions
Understanding Data and Encoding

Quiz
•
6th Grade - University
10 questions
Quiz de Programação em C

Quiz
•
9th - 12th Grade
10 questions
Fundamentos de Programación en Python

Quiz
•
6th Grade - University
10 questions
Questionário de Lógica e Programação

Quiz
•
10th Grade
Popular Resources on Quizizz
15 questions
Character Analysis

Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
10 questions
American Flag

Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension

Quiz
•
5th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25

Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers

Quiz
•
6th - 8th Grade
Discover more resources for Information Technology (IT)
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Taxes

Quiz
•
9th - 12th Grade
17 questions
Parts of Speech

Quiz
•
7th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression

Quiz
•
9th - 12th Grade
20 questions
Inequalities Graphing

Quiz
•
9th - 12th Grade
10 questions
Identifying equations

Quiz
•
KG - University