---
# System prepended metadata

title: Python 4.4

---

# Python 4.4

```python=

def Eratostenes(n):
    temp = [True] * (n + 1)
    primes = []
    zero = 0
    for i in range(2, n + 1):
        if temp[i]:
            primes.append(i)
            for j in range(i*i, n + 1, i):
                temp[j] = False
        else:
            primes.append(zero)
    return primes
    
        
def odwrotna(n):
    lista = []
    liczba_odwrotna = ""
    m = str(n)
    for i in range(len(m)):
        lista.append(m[i])
    lista.reverse()
    for element in lista:
        liczba_odwrotna += element
    return liczba_odwrotna


def palindromy(a, b):
    palindromiczne = []
    for i in range(a, b + 1):
        if i > 10:
            if str(i) == str(odwrotna(i)):
                palindromiczne.append(i)
    return palindromiczne

    

print(palindromy(8, 1000))
```