Question: 
Write a function to find the next smallest palindrome of a specified number.


Model's Code:
def next_smallest_palindrome(n):
    n += 1
    while True:
        if str(n) == str(n)[::-1]:
            return n
        n += 1



Sample Correct Code:
import sys
def next_smallest_palindrome(num):
    numstr = str(num)
    for i in range(num+1,sys.maxsize):
        if str(i) == str(i)[::-1]:
            return i


Asserts:
assert next_smallest_palindrome(99)==101
assert next_smallest_palindrome(1221)==1331
assert next_smallest_palindrome(120)==121


Tests:
Test 1 of 3: PASS
Test 2 of 3: PASS
Test 3 of 3: PASS

Test 100 of 974: 78/100 (78.0%): success