You are on page 1of 3

3/28/24, 2:45 PM Quiz 2 - Player (Section 1): Attempt review | Moodle-KALAM

Important Announcement : Start Date of Student Access Restrictions for KALAM HERE

Started on Thursday, 28 March 2024, 2:33 PM


State Finished
Completed on Thursday, 28 March 2024, 2:43 PM
Time taken 10 mins 5 secs
Grade 8.00 out of 10.00 (80%)

Question 1

Complete

Mark 1.00 out of 1.00

Question 2: What are the dimensions of the game window set to?

a. 400x400 pixels
b. 300x300 pixels
c. 200x300 pixels
d. 300x200 pixels

Question 2
Complete

Mark 1.00 out of 1.00

Question 1: What library is imported in the first line of the code?

a. PyPlot
b. PyGameGUI
c. Tkinter
d. PyGame

Question 3
Complete

Mark 1.00 out of 1.00

Question 10: What is the code missing to make it a playable game?

a. Game logic and user interaction


b. Background color
c. Game window dimensions
d. Player character

https://kalam.ump.edu.my/mod/quiz/review.php?attempt=11767&cmid=46925 1/3
3/28/24, 2:45 PM Quiz 2 - Player (Section 1): Attempt review | Moodle-KALAM

Question 4

Complete

Mark 0.00 out of 1.00

Question 7: What function is called to draw the player character on the screen?

a. draw_player_character()
b. drawplayer()
c. draw_player()
d. pygame.draw_player()

Question 5
Complete

Mark 0.00 out of 1.00

Question 5: What is the initial position of the player character on the X-axis (horizontal)?

a. 200
b. 150
c. 100
d. 300

Question 6

Complete

Mark 1.00 out of 1.00

Question 9: What is the purpose of the while True loop in this code?

a. It sets up the game window.


b. It draws the background color.
c. It initiates the game loop that runs indefinitely.
d. It defines the player character.

Question 7
Complete

Mark 1.00 out of 1.00

Question 4: What is the color of the player character (rectangle) set to?

a. Blue
b. Green
c. Yellow
d. Red

https://kalam.ump.edu.my/mod/quiz/review.php?attempt=11767&cmid=46925 2/3
3/28/24, 2:45 PM Quiz 2 - Player (Section 1): Attempt review | Moodle-KALAM

Question 8

Complete

Mark 1.00 out of 1.00

Question 8: What action is taken inside the game loop to display any changes made in the frame?

a. pygame.update_display()
b. pygame.display.update()
c. pygame.update_screen()
d. pygame.draw_screen()

Question 9
Complete

Mark 1.00 out of 1.00

Question 6: What is the initial position of the player character on the Y-axis (vertical)?

a. 200
b. 100
c. 50
d. 150

Question 10

Complete

Mark 1.00 out of 1.00

Question 3: What is the background color of the game window set to?

a. Green
b. Blue
c. Red
d. Yellow

https://kalam.ump.edu.my/mod/quiz/review.php?attempt=11767&cmid=46925 3/3

You might also like