https://github.com/nurulashraf/java-palindrome-checker
A simple Java program to check if a given string or number is a palindrome. It removes non-alphanumeric characters, ignores case, and handles errors like empty input. Includes a clean, efficient implementation with proper error handling.
https://github.com/nurulashraf/java-palindrome-checker
basic-algorithms beginner-friendly error-handling java palindrome string-manipulation text-processing
Last synced: about 2 months ago
JSON representation
A simple Java program to check if a given string or number is a palindrome. It removes non-alphanumeric characters, ignores case, and handles errors like empty input. Includes a clean, efficient implementation with proper error handling.
- Host: GitHub
- URL: https://github.com/nurulashraf/java-palindrome-checker
- Owner: nurulashraf
- License: mit
- Created: 2025-02-02T06:15:15.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2025-02-03T07:26:37.000Z (4 months ago)
- Last Synced: 2025-02-12T09:55:11.717Z (3 months ago)
- Topics: basic-algorithms, beginner-friendly, error-handling, java, palindrome, string-manipulation, text-processing
- Language: Java
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Java Palindrome Checker
## Description
A simple Java program to check if a given string or number is a palindrome. The program removes non-alphanumeric characters, ignores case sensitivity, and includes error handling for empty inputs.## Features
- Supports both strings and numbers
- Ignores case and special characters
- Provides proper error handling
- Uses a clean and efficient algorithm## Requirements
- Java 8 or later## Installation
1. Clone the repository:
```sh
git clone https://github.com/nurulashraf/java-palindrome-checker.git
```
2. Navigate to the project directory:
```sh
cd java-palindrome-checker
```## Usage
1. Compile the program:
```sh
javac src/palindromechecker/PalindromeChecker.java
```
2. Run the program:
```sh
java -cp src palindromechecker.PalindromeChecker
```
3. Enter a string or number when prompted.## Example
```
Enter a string or number: Racecar
The input is a palindrome.
```## Repository Structure
```
java-palindrome-checker/
│── src/
│ └── PalindromeChecker.java
│── README.md
└── LICENSE
```## License
This project is licensed under the [MIT License](LICENSE).