renix1

Link to view Python 3.x

Aug 15th, 2015
236
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.73 KB | None | 0 0
  1. # -*- coding:utf-8 -*-
  2. #video para usar como teste https://www.youtube.com/watch?v=Xzf_WqJ_bPU
  3. import webbrowser
  4. import time as t
  5. search = int(input("Você quer ganhar views? \n1 - Sim \n2 - Não \nEscreva aqui: "))
  6. if search == 1:
  7.     url_video = input("Digite o link do vídeo: ")
  8.     checar_url_video = len(url_video)
  9.     if checar_url_video <= 0:
  10.         print("Você não digitou o link do vídeo.")
  11.     else:
  12.         if checar_url_video >= 1:
  13.             print("Abrindo as páginas")
  14.             webbrowser.open("%s" % (url_video))
  15.             t.sleep(3)
  16.         while checar_url_video >= 1:
  17.             print("Abringo as páginas novamente")
  18.             t.sleep(2)
  19. else:
  20.     if search == 2:
  21.         print("Estamos saindo...")
  22.         exit(0)
  23.     elif search != 1 or 2:
  24.         print("Não entendemos, nos desculpe.")
Advertisement
Add Comment
Please, Sign In to add comment