/**
 * This function takes in two integers, start and stop, and returns a list of palindromic numbers between those two values (inclusive).
 * A palindromic number reads the same forwards and backwards. For example, 121 is a palindromic number.
 *
 * @param start The starting value for the range.
 * @param stop The stopping value for the range.
 * @return A list of palindromic numbers between start and stop.
 *
 * Examples:
 * findPalindromes(100, 200) => [101, 111, 121, 131, 141, 151, 161, 171, 181, 191, 200]
 */
fun findPalindromes(start: Int, stop: Int): List<Int> {

    val palindromes = mutableListOf<Int>()
    var num = start

    while (num <= stop) {
        if (num.toString() == num.toString().reversed()) {  // Check if the number is palindrome
            palindromes.add(num)
        }
        num++
    }

    return palindromes
}
/**
 * This function takes in two integers, start and stop, and returns a list of palindromic numbers between those two values (inclusive).
 * A palindromic number reads the same forwards and backwards. For example, 121 is a palindromic number.
 *
 * @param start The starting value for the range.
 * @param stop The stopping value for the range.
 * @return A list of palindromic numbers between start and stop.
 *
 * Examples:
 * findPalindromes(100, 200) => [101, 111, 121, 131, 141, 151, 161, 171, 181, 191, 200]
 */
fun findPalindromes(start: Int, stop: Int): List<Int> {
/**
 * This function takes in two integers, start and stop, and returns a list of palindromic numbers between those two values (inclusive).
 * A palindromic number reads the same forwards and backwards. For example, 121 is a palindromic number.
 *
 * @param start The starting value for the range.
 * @param stop The stopping value for the range.
 * @return A list of palindromic numbers between start and stop.
 *
 * Examples:
 * findPalindromes(100, 200) => [101, 111, 121, 131, 141, 151, 161, 171, 181, 191, 200]
 */
fun findPalindromes(start: Int, stop: Int): List<Int> {

    val palindromes = mutableListOf<Int>()
    var num = start

    while (num <= stop) {
        if (num.toString() == num.toString().reversed()) {  // Check if the number is palindrome
            palindromes.add(num)
        }
        num++
    }

    return palindromes
}