GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — TUI-apps/PythonExercises at main · learnbyexample/TUI-apps

Expand file tree

/

PythonExercises

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
/

PythonExercises

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
exercises
exercises
 
 
sample_files
sample_files
 
 
solutions
solutions
 
 
README.md
README.md
 
 
app_guide.md
app_guide.md
 
 
exercises.json
exercises.json
 
 
nums.txt
nums.txt
 
 
python_exercises.css
python_exercises.css
 
 
python_exercises.png
python_exercises.png
 
 
python_exercises.py
python_exercises.py
 
 
python_quiz.png
python_quiz.png
 
 
quiz.txt
quiz.txt
 
 

README.md

Outline

Python Exercises

This interactive TUI app includes exercises and multiple-choice questions intended to test the understanding of beginner to intermediate level Python learners.

Installation

This app is available on PyPI as pythonexercises. Example installation instructions are shown below, adjust them based on your preferences and OS.

# virtual environment
$ python3 -m venv textual_apps
$ cd textual_apps
$ source bin/activate
$ pip install pythonexercises

# launch the app
$ pythonexercises

Note
If you are on Windows, using the Windows Terminal is recommended. See this issue for Virtual Environment commands and other details.

To run the app without having to enter the virtual environment again, add this alias to .bashrc (or equivalent):

# you'll have to change the path
alias pythonexercises='/path/to/textual_apps/bin/pythonexercises'

As an alternative to manually managing such virtual environments, you can use https://github.com/pypa/pipx instead:

$ pipx install pythonexercises
$ pythonexercises

As yet another alternative, you can install textual (see Textual documentation for more details), clone this repository and run the python_exercises.py file. You'll need to install textual[syntax] to enable syntax highlighting (see documentation for more details).

Adjust the terminal dimensions for the widgets to appear properly, for example 84x25 (characters x lines). Here are sample screenshots:

Sample Python Exercise

Sample Python Quiz

Guide

See app_guide.md

Ebook

The exercise and quiz questions in this app have been adapted from my 100 Page Python Intro ebook.

License

Code snippets are licensed under MIT LICENSE.

Exercise questions and associated files (like exercises.json and quiz.txt) are licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.