#C14085. Count Numerical Palindromes

    ID: 43695 Type: Default 1000ms 256MiB

Count Numerical Palindromes

Count Numerical Palindromes

Given two integers start and end, count the number of numerical palindromes within the inclusive range [start, end].

A numerical palindrome is a number that reads the same forward and backward. In mathematical terms, a number \( n \) is a palindrome if \( n = \text{reverse}(n) \), where \( \text{reverse}(n) \) denotes the number formed by reversing the digits of \( n \).

inputFormat

The input consists of a single line with two space-separated integers: start and end, representing the beginning and end of the range.

outputFormat

Output a single integer which is the count of numerical palindromes between start and end (inclusive).

## sample
1 9
9