id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

apcsaPrimitivesIntPalindrome


Given an int, determine if its base-10 representation (as a String) is a palindrome. A palindrome reads the same forwards and backward. The sign (-) is part of the representation and should be considered.


HINT: checking for a palindrome involves a loop.

apcsaPrimitivesIntPalindrome(121) → true
apcsaPrimitivesIntPalindrome(123) → false
apcsaPrimitivesIntPalindrome(5) → true

...Save, Compile, Run (ctrl-enter)

public boolean apcsaPrimitivesIntPalindrome(int num) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 130

Copyright Nick Parlante 2017 - privacy