Skip to content

Conversation

@anishmsspt
Copy link

@anishmsspt anishmsspt commented Oct 28, 2025

Title: Feat: Add ASCII Art Countdown Timer

Description

This pull request adds a new script, countdown_timer.py, which is a feature-rich, command-line countdown timer.

The script provides a highly visual countdown by using large ASCII art to display the remaining seconds. It clears the screen on each tick to create a smooth, updating display.

Key Features:

  • Takes a duration (in seconds) as user input.
  • Displays the remaining time using large, multi-line ASCII numbers.
  • Clears the terminal screen (os.system) for each new second.
  • Shows a "TIME'S UP!" banner upon completion.
  • Simulates an alarm with a blinking "BEEP!" message.
  • Includes error-handling for non-numeric input (ValueError).
  • Gracefully handles user cancellation (KeyboardInterrupt).
  • Prompts the user to start another countdown, with a main loop for re-running.

This script is a great addition for anyone looking for a more engaging and visual timer for their terminal.

Type of Change

  • New feature (A new, self-contained Python program)
  • Bug fix
  • Documentation update
  • Refactor

How This Has Been Tested

I have tested this script locally on my machine:

  1. Ran the script: python countdown_timer.py
  2. Entered a valid number (e.g., 10) and observed the countdown proceed correctly.
  3. Verified that the "TIME'S UP!" banner and "BEEP!" notifications appear at zero.
  4. Tested the "run again" prompt (y and n).
  5. Tested invalid input (e.g., abc) and confirmed the ValueError message appears.
  6. Tested Ctrl+C during a countdown and confirmed it exits gracefully.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant