Quiz String, Text Files, Exception

Quiz String, Text Files, Exception

University

10 Qs

Similar activities

Bootstrap

Bootstrap

University

10 Qs

Asesmen Pengetahuan Mengenal Microsoft PowerPoint

Asesmen Pengetahuan Mengenal Microsoft PowerPoint

University

10 Qs

Python

Python

University

10 Qs

Java quiz based on inheritance

Java quiz based on inheritance

University

10 Qs

Quiz 7

Quiz 7

University

11 Qs

MS Excel - Day 03

MS Excel - Day 03

University

10 Qs

Bahasa Pemrograman Python

Bahasa Pemrograman Python

University

10 Qs

Python - Functions

Python - Functions

University

10 Qs

Quiz String, Text Files, Exception

Quiz String, Text Files, Exception

Assessment

Quiz

Created by

Syifa Nurhayati

Computers

University

1 plays

Medium

10 questions

Show all answers

1.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

x = "apple"

Mana saja pilihan yang akan mencetak huruf p?

print(x[2])

print(x[1])

print(x[-1])

print(x[-2])

2.

FILL IN THE BLANK QUESTION

1 min • 1 pt

Media Image


Angka terakhir yang dicetak program tersebut adalah...

3.

FILL IN THE BLANK QUESTION

1 min • 1 pt

a = "one"

b = "two"

print((a+b+a)*1) akan menghasilkan output...

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

print("{2}-{0}-{1}".format('September', 21, 2022))

21-September-2022

September-21-2022

2022-September-21

Syntax Error

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

Agar tercetak output seperti pada gambar, kode yang tepat adalah ...

print(f"{judul:.>50d}{halaman:.<5d}")

print(f"{judul:.<50s}{halaman:.>5d}")

print(f"{judul:.<50d}{halaman:.>5f}")

print(f"{judul:.>50s}{halaman:.<5d}")

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Method yang akan mengembalikan setiap baris menjadi elemen dalam list adalah ...

read()

open()

readline()

readlines()

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

Untuk membaca kata "Semangat" apa yang harus dilakukan?

file = open('pesan.txt', "r")

file.read(8)

file.read(7)

file.read(0,7)

file.read([0:7])

8.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Error manakah yang paling susah dicari penyebabnya?


Semantic Error

Runtime Error

Syntax Error

9.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Proses mengidentifikasi dan menyelesaikan error disebut dengan "Debugging"?

True

False

10.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Kita dapat menggunakan syntax "try" tanpa menggunakan "except"

True

False

Explore all questions with a free account

or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?