Search Header Logo

Soal Pilihan Ganda Pemrograman Python (1)

Authored by Fatkhul Huda

Science

University

Used 2+ times

Soal Pilihan Ganda Pemrograman Python (1)
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Apa yang dilakukan fungsi `print()` dalam Python?

Menyimpan data ke dalam file

Menampilkan data di layar

Menghitung nilai rata-rata

Menghapus data dari memori

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Bagaimana cara mendeklarasikan variabel `x` dengan nilai 10 dalam Python?

`int x = 10`

`x = 10`

`let x = 10`

`var x = 10`

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Fungsi mana yang digunakan untuk mengubah string menjadi huruf kapital dalam Python?

`capitalize()`

`upper()`

`title()`

`lower()`

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Apa hasil dari ekspresi `3**2` dalam Python?

6

9

8

12

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Bagaimana cara membuat list kosong dalam Python?

`[]`

`()`

`{}`

`list()`

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Manakah dari berikut ini yang merupakan metode string untuk menghapus spasi dari awal dan akhir string?

`strip()`

`trim()`

`remove()`

`delete()`

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Apa output dari kode berikut: `print([1, 2, 3] + [4, 5])`?

`[1, 2, 3, 4, 5]`

`[1, 2, 3] [4, 5]`

`[1, 2, 3, [4, 5]]`

`[4, 5, 1, 2, 3]`

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Microsoft

Continue with Microsoft

or continue with

Facebook

Facebook

Apple

Apple

Others

Others

Already have an account?