Skip to main content

Module that count unique chars in string or file

Project description

Character Counter

This Python application allows you to count the number of unique characters in a provided string or a text file.

Usage

Running the Application

Navigate to the src directory and run the command_line.py script with the desired options:

python command_line.py --string "your_string_here"

or

python command_line.py --file /path/to/your/text_file.txt

Function Details

count_unique_chars(string=None, file_path=None)

Count the number of unique characters in the input string.

Parameters:

  • string (str): The string in which to count unique characters.
  • file_path (str): The path to the input text file.

Returns:

  • int: The count of unique characters in the input string.

Raises:

  • TypeError: If the input is not a string.

Author

Volodymyr Perehuda

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

char_counter_vp-0.0.4.tar.gz (29.1 kB view details)

Uploaded Source

Built Distribution

char_counter_vp-0.0.4-py3-none-any.whl (27.6 kB view details)

Uploaded Python 3

File details

Details for the file char_counter_vp-0.0.4.tar.gz.

File metadata

  • Download URL: char_counter_vp-0.0.4.tar.gz
  • Upload date:
  • Size: 29.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for char_counter_vp-0.0.4.tar.gz
Algorithm Hash digest
SHA256 4fde4c61dad2e4db82c12e33b64709ee62a0afbf4fc3c376fededad5fb07f6f7
MD5 4353dbc7c86fd5452a7f5460da13ca91
BLAKE2b-256 aa90cad412e650d78f4fceae31b6a88a8091ccd9e7daec7b1600381931849bef

See more details on using hashes here.

File details

Details for the file char_counter_vp-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for char_counter_vp-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 407282ee13b5d8c7f644d5444db131f11a30719211c5e42d674a0e447c281635
MD5 a1fdc50681d1a51c3d47ef8c66351b25
BLAKE2b-256 2f27eef809e224d6f4a32ba12c1791951eaf22a0f8ab24342cf81c41cb0f5737

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page