Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

7 Commits
Β 
Β 
Β 
Β 

Repository files navigation

Prime Power

Brute Force Approach
A Python project to determine whether a given number is a prime number, a power of another number, or neither.
This project was developed in my 1st year, 1st semester as part of the LifeSkills & Python program conducted by the ARJUNA Trust.**

πŸš€ Features

  • Prime Number Detection: Identifies if an input is a prime number.
  • Power Detection: Checks if a number is a perfect power (can be expressed as ( a^b ) with integers ( a > 1, b > 1 )).
  • User-Friendly Input: Simple prompts for any integer and displays the result.
  • Educational Purpose: Demonstrates logical programming for beginners using Python.

πŸ’» Getting Started

Prerequisites

  • Python 3.x

How to Run

  1. Clone the repository

    git clone https://github.com/DRV-Sai-Siddarth/Prime-Power.git
    cd Prime-Power
    
  2. Run the program

    python prime_power.py
    

    If your main file has a different name, replace prime_power.py with its name.

  3. Follow the prompt

    • Enter a number when asked.
    • The output will state if the number is Prime, Power, or Neither.

πŸ“ Example Usage

Enter a number: 27 27 is a power (3^3).

Enter a number: 13 13 is a prime number.

Enter a number: 20 20 is neither a prime nor a power.

text


πŸ“‚ Project Structure

Prime-Power/ β”œβ”€β”€ prime_power.ipynb # Main Python script β”œβ”€β”€ README.md # Project documentation

text


πŸ‘¨β€πŸ’» Author

  • DRV Sai Siddarth P Sai Santhosh Kumar C Nikhil

πŸŽ“ Acknowledgements

  • Project developed during the LifeSkills & Python program by ARJUNA Trust

πŸ“„ License

This project is open-source and available for educational use.


Ready to check if a number is prime or a power? Clone and try it out!

About

This is my first repository.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages