Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Game Rules | Crafting a Classic Hangman Game
Crafting a Classic Hangman Game
course content

Зміст курсу

Crafting a Classic Hangman Game

bookGame Rules

How to work with Projects

Hangman rules

Function plan

Final playable game version

Preparation for the Hangman!

First, we need to import the libraries required for the game and define new functions.

The first function, named load_words(), is used to retrieve all words from a given file. One random word from this file will be chosen for the game process in the future.

Завдання
test

Swipe to show code editor

  1. Import the random library.
  2. Import the string library.
  3. Define the load_words function to load words from a file.
  4. Initialize the word_list variable to store the words for the game.
  5. Return the word_list.

Mark tasks as Completed
Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

How to work with Projects

Hangman rules

Function plan

Final playable game version

Preparation for the Hangman!

First, we need to import the libraries required for the game and define new functions.

The first function, named load_words(), is used to retrieve all words from a given file. One random word from this file will be chosen for the game process in the future.

Завдання
test

Swipe to show code editor

  1. Import the random library.
  2. Import the string library.
  3. Define the load_words function to load words from a file.
  4. Initialize the word_list variable to store the words for the game.
  5. Return the word_list.

Mark tasks as Completed
Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Секція 1. Розділ 1
AVAILABLE TO ULTIMATE ONLY
We're sorry to hear that something went wrong. What happened?
some-alt