Palindrome Number

Easy Solved

Description

Determine whether an integer is a palindrome. An integer is a palindrome when it reads the same backward as forward.

Do not convert the integer to string in your main logic if you want to practice numeric approach — but any valid solution that prints correct output is accepted here.

Example 1:

Input: 121

Output: true

Example 2:

Input: -121

Output: false

Example 3:

Input: 10

Output: false

Note:

Runner reads a single integer from stdin and expects a single output string true or false (lowercase). Input example: 121 → Output: true.

Your Submissions

No submissions yet.

Discuss

Share numeric vs string solutions, edge cases (negative numbers, trailing zeros), and complexity trade-offs.

Test Cases

Test Case 1
Test Case 2
Test Case 3