I hereby claim:
- I am s3ctur on github.
- I am s3ctur (https://keybase.io/s3ctur) on keybase.
- I have a public key ASCS189l0NTTfJz9X9MdofcLUrhDgHXP7Q-nm_1W6oWzyAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
a = [1, 4, 9, 16, 25, 36, 49, 64, 81, 100]; b = list(filter(lambda x: x % 2 == 0, a)); print(b) |
def getPal(): | |
x = input('Please enter a word to check if it is a palindrome: ') | |
y = list(x) | |
z = list(reversed(y)) | |
if z == y: | |
print(str(x) + ' is a palindrome.') | |
else: | |
print(str(x) + ' is not a palindrome.') | |
x = range(1, 101) | |
y = [] | |
foo = int(input('Please choose a number between 1-100: ')) | |
for elem in x: | |
if elem % foo == 0: | |
y.append(elem) | |
print(('Out of 100, the following numbers are divisors for ') + str(foo) + (': ') + str(y)) |
##a = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89] | |
##b = [] | |
##for element in a: | |
## if element <= 5: | |
## b.append(element) | |
##print(b) | |
##foo = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89]; b = list(filter(lambda x: x <= 5, foo)); print(b) |
#!/usr/local/bin/python3 | |
number = input("Please enter a number ") | |
evenodd = int(number) % 2 | |
if int(evenodd) == 0: | |
print(str(number) + " is an even number.") | |
else: | |
print(str(number) + " is an uneven number") |
##a = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89] | |
##b = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] | |
##c = set(a).intersection(b) | |
##print(c) | |
import random | |
samp = [] | |
def getSamp(): |