import math


def sieve_eratosthenes(n: int) -> list:
    """
    Finds all the Primes using the upper limit 'n' using
    Eratosthenes's Sieve algorithm
    More here: https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes#Pseudocode

    :param n: The upper limit of numbers to be tested for bieng primes
    :returns: list containing all the primes less than n
    """
    A = [True] * n
    primes = []
    for i in range(2, math.ceil(math.sqrt(n))):
        if A[i] is True:
            for j in range(i**2, n, i):
                A[j] = False

    for i in range(len(A)):
        if A[i] is True:
            primes.append(i)
    return (primes)