Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ###1
- # paragraph = input("Enter a long paragraph: ")
- # # that sentences will end with a .
- # sen = paragraph.split(".")
- # print("\n"*5)
- # for s in sen:
- # print(s)
- # print("\n")
- ###2
- # word = input("Enter a random word: ")
- # answer = ""
- # for c in word:
- # if c.lower() in "aeiou":
- # answer += c.upper()
- # else:
- # answer += c.lower()
- # print(answer)
- ###3
- # ask the user for what they want to do
- # response = ""
- # while response != "exit":
- # response = input("What do you want to do today? \n").lower()
- # if response == "music":
- # print("I'll open Spotify :)")
- # elif response == "movies":
- # print("I'll open Netflix :)")
- # elif response == "go out":
- # print("I'll open Uber :)")
- # else:
- # print("I don't know what you're saying. \nType "+ '"exit"' + " to exit the program.")
- # response = ""
- # contact = []
- # while response != "0":
- # print("Enter 1 to add contact")
- # if len(contact) > 0:
- # print("Enter 2 to delete contact")
- # print("Enter 3 to print all contacts. ")
- # response = input("Enter your choice: ")
- # if response == "1":
- # name = input("Enter the name you want to add: ")
- # if name in contact:
- # print("Name already present.")
- # else:
- # contact.append(name)
- # elif response == "2" and len(contact) > 0:
- # name = input("Enter the name you want to delete: ")
- # if name in contact:
- # contact.remove(name)
- # else:
- # print("Name not there in the list.")
- # elif response == "3" and len(contact) > 0:
- # contact.sort()
- # print("These are the contacts in your list- ")
- # for c in contact:
- # print(c)
- # print("\n")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement