week 6
This commit is contained in:
Binary file not shown.
@@ -0,0 +1,9 @@
|
||||
s = input("Do you agree? ")
|
||||
s = s.lower()
|
||||
|
||||
if s in ["y", "yes"]:
|
||||
|
||||
print("Agreed.")
|
||||
|
||||
else:
|
||||
print("Not Agreed.")
|
||||
@@ -0,0 +1,5 @@
|
||||
from PIL import Image, ImageFilter
|
||||
|
||||
before = Image.open("bridge.bmp")
|
||||
after = before.filter(ImageFilter.BoxBlur(10))
|
||||
after.safe("out.bmp")
|
||||
@@ -0,0 +1,3 @@
|
||||
for _ i in range(3):
|
||||
print("Meow")
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
s = input("s: ")
|
||||
t = input ("t: ")
|
||||
|
||||
if s == t:
|
||||
print("Same")
|
||||
else:
|
||||
print("Different")
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
s = input("s: ")
|
||||
|
||||
t = s.capitalize()
|
||||
|
||||
print(f"s: {s}")
|
||||
print(f"t: {t}")
|
||||
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
words = set()
|
||||
|
||||
def check(word):
|
||||
return word.lower() in words
|
||||
|
||||
def load(dictionary):
|
||||
with open(dictionary) as file:
|
||||
words.update(file.read().splitlines())
|
||||
return True
|
||||
|
||||
def size():
|
||||
return len(words)
|
||||
|
||||
def unload():
|
||||
return True
|
||||
@@ -0,0 +1 @@
|
||||
print ("Hello World")
|
||||
@@ -0,0 +1,12 @@
|
||||
while True:
|
||||
n = int(input("Height: "))
|
||||
if n > 0:
|
||||
break
|
||||
|
||||
for i in range(n):
|
||||
print("#")
|
||||
|
||||
|
||||
for i in range(4):
|
||||
print("?", end ="")
|
||||
print()
|
||||
@@ -0,0 +1,6 @@
|
||||
before = input("Before: ")
|
||||
print("After: ", end="")
|
||||
for c in before:
|
||||
print(c.upper(), end="")
|
||||
|
||||
print()
|
||||
Reference in New Issue
Block a user