Q:

print numbers as big as second parameter python

I'm trying to cut all integers from a list which are lower than a given parameter
lis = [23, 52, 91, 75, 3, 68, 17, 88, 105]
lis2 = []

y = int(input("give a minimum number"))

def printbigenough(lis, y):
    for i in range(len(lis)):
        if lis[i] > y: #checks if i is bigger than the given input
            lis2.append(i) # adds i to the second list (sort of)
    print(lis2)

printbigenough(lis, y)

however, instead of returning the numbers which are higher. the program is just printing what positions in the list have higher numbers. does anyone know how to fix this?
also, if this is a poorly constructed code or question i'm sorry... i'm still new at programming

A:

That's because you call lis2.append(i). You must call lis2.append(lis[i]), like this:
lis = [23, 52, 91, 75, 3, 68, 17, 88, 105]
lis2 = []

y = int(input("give a minimum number: "))

def printbigenough(lis, y):
    for i in range(len(lis)):
        if lis[i] > y: #checks if i is bigger than the given input
            lis2.append(lis[i]) # adds the item to the second list (sort of)
    print(lis2)

printbigenough(lis, y)

i is the index of the item, not the item

