New update is available. Click here to update.

Topics

Check whether a given number * ’n’* is a palindrome number.

```
Palindrome numbers are the numbers that don't change when reversed.
You don’t need to print anything. Just implement the given function.
```

```
Input: 'n' = 51415
Output: true
Explanation: On reversing, 51415 gives 51415.
```

Detailed explanation

```
1032
```

```
false
```

```
1032, on being reversed, gives 2301, which is a totally different number.
```

```
121
```

```
true
```

```
121, on being reversed, gives 121, which is the same.
```

```
The expected time complexity is O(log(n)).
```

```
1 <= n <= 10^9
Time Limit: 1 sec
```