Skip to content

Commit 131ecfa

Browse files
refaactor 9
1 parent 61f2474 commit 131ecfa

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

cpp/_9.cpp

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,3 @@
1-
/**
2-
* 9. Palindrome Number
3-
*
4-
* Determine whether an integer is a palindrome. An integer is a palindrome when it reads the same backward as forward.
5-
6-
Example 1:
7-
8-
Input: 121
9-
Output: true
10-
Example 2:
11-
12-
Input: -121
13-
Output: false
14-
Explanation: From left to right, it reads -121. From right to left, it becomes 121-. Therefore it is not a palindrome.
15-
Example 3:
16-
17-
Input: 10
18-
Output: false
19-
Explanation: Reads 01 from right to left. Therefore it is not a palindrome.
20-
Follow up:
21-
22-
Coud you solve it without converting the integer to a string?
23-
*/
24-
251
class Solution1 {
262
/**This is a Java translation, while its Java counterpart could be accepted perfectly, this one failed due to
273
* Char 21: runtime error: signed integer overflow: 746384741 * 10 cannot be represented in type 'int' (solution.cpp)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy