def main(): entrada = int(input('digite o número da coluna: ')) for a in range(10): sy('clear') print(' ' * get()[0] + '\n' * a) print(f"\r{' ' * entrada}O") input('pressione enter para continuar.')
def main(): nome = input('Nome completo: ') endereço = input('Endereço: ') cep = input('Cep: ') telefone = input('Telefone: ') sy('clear') print(nome, endereço, cep + ' - ' + telefone, sep='\n')
def hud_final(gastos,receitas,fechamento): sy('cls') print('-'*40) print(f'{"LISTAGEM DE VALORES DE GASTOS":^40}') print('-'*40) print(f'{"NOME":.<30}{"VALOR"}') print('-'*40) for item in gastos: print(f'''{item:.<30}R${gastos[item]:<7}''') print('-'*40) print(f'{"LISTAGEM DE VALORES DE RECEITAS":^40}') print('-'*40) print(f'{"NOME":.<30}{"VALOR"}') print('-'*40) for item in receitas: print(f'''{item:.<30}R${receitas[item]:<7}''') print('-'*40) print(f'Vai te sobrar : R${fechamento}') print('-'*40) print(''' Se o numero acima der positivo, significa que suas finanças mediante ao que nos foi passado está no verde. Caso o número seja negativo, rode o programa novamente para ter certeza de que esrevera todos os numeros corretamente e se escreveu e ainda assim o numero acima estiver negativo... suas finanças estão no vermelho infelizmente.\n''') x = input('APERTE ENTER PARA VOLTAR AO MENU\n') return True
def main(): linha = int(input('digite uma linha: ')) sy('clear') for a in range(linha): print('\n' * a + 'O', end='\r') sleep(0.08) sy('clear')
def main(): sy("cls||clear") parse.add_option("-t", "--target", dest="target", type=str) parse.add_option("-p", "--ports", dest="ports", type=str) parse.add_option("-P", "--protocol", dest="proto", type=str) parse.add_option("-T", "--timeout", dest="timeout", type=str) parse.add_option("-d", "--threads", dest="threads", type=str) parse.add_option("-v", "--verbose", action="store_true", dest="verb", default=False) (opt, args) = parse.parse_args() default = [] if opt.target != None: target = opt.target if opt.verb: verb = True else: verb = False if opt.ports != None: ports = opt.ports ports = getPorts(ports) if not ports: exit("[!] Invalid Ports Selected !!!") else: default.append("ports=21,22,23,25,51,80,135,139,443,444,445") ports = [21, 22, 23, 25, 51, 80, 135, 139, 443, 444, 445] if opt.proto != None: proto = opt.proto.lower() if proto not in ("tcp", "udp"): exit("[!] Invalid Connection Protocol !!!\n") else: default.append("protocol=TCP") proto = "tcp" if opt.timeout != None: timeout = opt.timeout if timeout.isdigit(): timeout = int(timeout) elif isFloat(timeout): timeout = float(timeout) else: exit("[!] Invalid Timeout selected !!!\n") else: default.append("timeout=2") timeout = 2 if opt.threads != None: threads = opt.threads if not threads.isdigit(): exit("[!] Invalid Number Of Threads!!!\n") else: threads = int(threads) else: default.append("threads=5") threads = 5 if default: print("[*] Using default config of:") print("\n".join(default)) print("\n[~] Scanning ...\n") startScan(target, ports, proto, timeout, threads, verb) printOpenPorts() else: print(parse.usage) exit(1)
def main(): colunas, linhas = get() linha = int(input('linha: ')) if not 0 <= linha <= linhas: raise ValueError('erro: linha fora do intervalo permitido') caracteres = input('caracteres: ') sy('clear') print('\n' * (linha - 1)) print(caracteres.center(colunas))
def pip(): libs = [ 'pymysql', 'cx_Oracle', 'psycopg2', 'pymongo', 'wget', 'python-nmap', 'prompt_toolkit', 'GitPython' ] for i in libs: import pip pip.main(['install', i]) sy("clear")
def download_repo( self): #being called from function definition downloading_message import git # Check out via HTTPS QMessageBox.information(self, 'Info', "Downloading...") git.Repo.clone_from('https://github.com/addddd123/Osdag', 'new_update') QMessageBox.information(self, 'Info', "Downloaded Successfully") os.sy()
def main(): linha = int(input('linha: ')) coluna = int(input('coluna: ')) b, a = get() intervalos = (0 <= linha <= a - 5, 0 <= coluna <= b - 5) if not all(intervalos): raise ValueError('linha e/ou coluna fora do intervalo permitido') sy('clear') print('\n' * linha) print('\n'.join(f"{' ' * coluna}{a}" for a in quadrado))
def pegar_entrada(texto: str, itens: Iterable[str], texto2: str = False) -> str: """Pega a entrada do usuário até ele responder uma entrada adequada.""" resposta = input(texto).lower() sy('clear') while not all([resposta != '', resposta in itens]): print('\nResposta errada. por favor, insira uma resposta aceitável.\n') if texto2: print(texto2) resposta = input(texto).lower() sy('clear') return resposta
def main(): opção = int(input('triângulo, quadrado, sair [1/2/3]?: ')) if opção == 3: return print('tchau!') linha = int(input('linha: ')) coluna = int(input('coluna: ')) b, a = get() intervalos = (0 <= linha <= a - 7, 0 <= coluna <= b - 12) if not all(intervalos): raise ValueError('linha e/ou coluna fora do intervalo permitido') sy('clear') print('\n' * linha) objeto = triângulo if opção == 1 else quadrado print('\n'.join(f"{' ' * coluna}{a}" for a in objeto))
def remove(): pass_sql = checksql() inp = input('Input Path Web [ex: "/var/www/"] : ') if not inp: inp = '/var/www/' sy('rm -r /opt/papazolaControlServerApps') sy('rm -r %spapazolaControlServer' % (inp, )) sy("mysql -u root -p'%s' -e 'drop database papazolaControl;'" % (pass_sql, )) import subprocess a = subprocess.Popen('ps aux | grep /opt/papazolaControlServerApps/', shell=True, stdout=subprocess.PIPE).stdout a = str(a.read()) a = a.split("'") a = a[1] a = a.split(' ') b = [] for c in a: if c: b.append(c) b = b[1] print('killing PID : ' + str(b)) sy('kill -9 ' + str(b))
def stat_ask(self, statvar): # This variable contains the key to be used for each teams stat value. curstat = statvar # Try except takes input as raw_input then converts it to int # If that fails then it ouputs the error and tries again. try: sy('clear') # Clears Screen. Bear in mind. This won't work in Windows. print 'Home Team %s?' % curstat self.Home[curstat] = int(raw_input('> ')) print 'Visitor %s?' % curstat self.Visitor[curstat] = int(raw_input('> ')) except ValueError: print 'Type a Number!' self.stat_ask(curstat)
def selecionar(self): while True: sy('cls | clear') print('Cadastro de Clientes\n') for num, item in enumerate(self.itens): print(f'{num} - {item}') try: opcao = int(input('\nOpção: ')) except: continue print() if opcao in self.dicio: self.dicio[opcao]() else: print('Opção inválida') sleep(1)
def main(): while True: sy('clear') print(menu) opção = int(input('opção: ')) if opção == 1: break elif opção == 2: número = float(input('digite um número: ')) if número >= 0: print(f"{número * 0.5:0.2f}") else: raise ValueError( 'não é possível calcular a raiz quadrada de um número negativo' ) else: raise ValueError('opção inválida')
def main(): a, b, c, d, e, f = '═║╔╗╚╝' funcoes = {'1': nome, '2': codigo, '3': data} while True: sy('clear') print(c + a * 78 + d) print(b + ' ' * 78 + b) print(b + ' ' * 10 + 'Menu Relatórios' + ' ' * 53 + b) print(b + ' ' * 78 + b) print(b + ' ' * 10 + '1 - Por nome' + ' ' * 56 + b) print(b + ' ' * 10 + '2 - Por código' + ' ' * 54 + b) print(b + ' ' * 10 + '3 - Por data' + ' ' * 56 + b) print(b + ' ' * 10 + '4 - Fim' + ' ' * 61 + b) print(b + ' ' * 78 + b) print(e + a * 78 + f) funcoes.get(input('Opção: '), exit)() sleep(1)
def main(): menu = """ Menu de consultas 0 - Fim 1 - Clientes 2 - Produtos 3 - Faturas 4 - Estoque """.strip().split('\n') coluna = int(input('digite a coluna: ')) menu = '\n'.join((' ' * coluna + a for a in menu)) while True: sy('clear') print(menu) opção = input('opção: ') if not opção: exit()
def __call__(self, event): if event.Key == 'Left' and event.MessageName == 'key up': sy('clear') if self.tela - 1 in range(len(self.texto)): self.tela -= 1 print(self.texto[self.tela]) else: print(self.texto[0]) print('\naviso: não tem como retroceder mais que o início') elif event.Key == 'Right' and event.MessageName == 'key up': sy('clear') if self.tela + 1 in range(len(self.texto)): self.tela += 1 print(self.texto[self.tela]) else: print(self.texto[-1]) print('\naviso: não tem como avançar mais que o final')
def main(): O = cycle((0, )) candidatos = Counter(dict([a, next(O)] for a in range(5))) while True: sy('clear') print(menu) opção = int(input('opção: ')) if opção == 5: break candidatos[opção] += 1 import pdb pdb.set_trace() sy('clear') items = list(candidatos.items())[1:-1] print('vencedor:', max(items, key=lambda x: x[1])[0]) print('votos brancos:', candidatos[4]) print('votos nulos:', candidatos[0]) print('número de eleitores que votaram:', sum(candidatos.values()))
def partida(adversario: str, jogador: str) -> str: """Função que executa uma partida do jogo da velha.""" lista = MinhaLista(' ' * 9) simbolos = {'usuário': '❌', adversario: '⭕'} # ✖ ◽ ◻ funcoes = {'usuário': usuario, 'usuário2': usuario, 'máquina': maquina} venc = vencedor(simbolos, lista) while not venc: print(grade.format(*numerar(lista))) jogador = inverter(jogador, ['usuário', adversario]) print(f"jogador: {jogador}, simbolo: {simbolos[jogador]}") funcao = funcoes[jogador] numero = funcao(lista.vazios(), grade.format(*numerar(lista))) lista[numero - 1] = simbolos[jogador] sy('clear') venc = vencedor(simbolos, lista) print(f"{venc} venceu!" if venc != 'empate' else f"{venc}!") sleep(1) sy('clear') return venc
def main(): notas = ([10, 500], [50, 100]) total_saque = 0 while True: sy('clear') print(menu) opção = int(input('opção: ')) if opção == 1: saque = float(input('digite o valor a sacar: ')) resto50 = saque % 50 quantidade = (saque - resto50) // 50 if quantidade > notas[1][1]: raise SystemError('não há notas de 50 o suficiente') resto10 = resto50 % 10 if resto10 > 0: raise ValueError('suas notas precisam ser mod de 50 e/ou 10') quantidade2 = resto50 // 10 if quantidade2 > notas[0][1]: raise SystemError('não há notas de 10 o suficiente') notas[1][1] -= quantidade notas[0][1] -= quantidade2 total_saque += saque print(f"saque de {saque} com {50 * quantidade} notas de 50\n" f"e {10 * quantidade2} notas de 10") elif opção == 2: depósito = float(input('digite o valor para o depósito:')) resto50 = depósito % 50 quantidade = (depósito - resto50) // 50 resto10 = resto50 % 10 if resto10 > 0: raise SystemError('suas notas precisam ser mod de 50 e/ou 10') quantidade2 = resto50 // 10 notas[1][1] += quantidade notas[0][1] += quantidade2 print(f"depósito de {depósito} com {50 * quantidade} notas de 50\n" f"e {10 * quantidade2} notas de 10") elif opção == 3: print(f"notas de 50 = {notas[1][1]}, notas de 10 = {notas[0][1]}") print(f"valor total de saque = {total_saque}") else: exit() input('precione enter para continuar')
def main(): linhas = int(input('digite a quantidade de linhas: ')) dicio = { '1': range(2, linhas, 2), '2': range(1, linhas), '3': range(2, linhas), '4': range(linhas, 0, -1) } while True: sy('clear') print(menu) opção = input('opção: ') if opção == '0': exit() elif opção not in '01234': raise ValueError('escolha uma opção válida') caracter = input('digite o caracter: ') for a in dicio[opção]: print(caracter * a) sleep(1)
def main(): notas = [] while True: sy('clear') print(menu) opção = int(input('opção: ')) if opção == 1: for a in range(1, 11): nota = float(input(f"nota {a}: ")) while nota not in range(0, 11): nota = float(input(f"nota {a}: ")) notas.append(nota) elif opção == 2: nota = float(input('nota à ser pesquisada: ')) while nota not in range(0, 11): nota = float(input('nota à ser pesquisada: ')) print('nota no vetor' if nota in notas else 'nota fora do vetor') input('precione enter para continuar') elif opção == 3: print(*notas) input('precione enter para continuar') else: break
def main(): linha = int(input('digite uma linha: ')) coluna = int(input('digite uma coluna: ')) sy('clear') for a in range(linha): print('\n' * a + 'O', end='\r') sleep(0.08) sy('clear') for b in range(1, coluna + 1): print('\n' * a + ' ' * b + 'O', end='\r') sleep(0.08) sy('clear')
def main(): parse.add_option('-t', '-T', '--TARGET', '--target', dest="target", type="string") parse.add_option("-a", "-A", "--ALL", '--all', action='store_true', dest="all", default=False) parse.add_option("-f", "-F", "--FOUND-ME", '--found-me', action='store_true', dest="fme", default=False) parse.add_option("-n", "-N", "--NETWORK", '--network', action='store_true', dest="network", default=False) parse.add_option('-c', '-C', '--CHECK', '--check', dest="check", type="string") parse.add_option("-e", "-E", "--EXAMPLES", '--examples', action='store_true', dest="ex", default=False) parse.add_option("-v", "-V", "--VERSION", action='store_true', dest="ve", default=False) (options, args) = parse.parse_args() if options.target != None and not options.all: target = options.target try: test = open(target, 'r') res = True except: res = False if res == False: if target[:8] == "https://": host = target[8:] elif target[:7] == "http://": host = target[7:] else: host = target target = host def SpyIp(target): if check == True: if ',' in target: targets = target.split(',') print("[@] Scanning [ {} ] Sites...".format( str(len(targets)))) for i in targets: try: ip = socket.gethostbyname(i) print("[*] TARGET> {}\n[*] IP> {}\n========". format(i, ip)) except socket.error: print( "[*] TARGET> {}\n[!] IP> Cod404: Server Not Found !!!" .format(i)) except KeyboardInterrupt: print(" ") break else: print("[~] Connecting....{}\n".format(target)) try: ip = socket.gethostbyname(target) print( "[*] TARGET> {}\n[*] IP> {}\n========".format( target, ip)) except socket.error: print( "[~] TARGET> {}\n[!] IP> Cod404: Server Not Found !!!" .format(target)) except KeyboardInterrupt: pass exit(1) else: print("[!] Please Check Your Internet Connection !!!") exit(1) SpyIp(target) else: targets = open(target, 'r') for t in targets: t = t.strip() def checker(): try: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t ip = socket.gethostbyname(host) run = socket.create_connection((ip, 80), 2) return True except: pass return False if checker() == True: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t try: ip = socket.gethostbyname(host) print("[*] TARGET> {}\n[*] IP> {}\n========".format( t, ip)) except socket.error: pass except KeyboardInterrupt: pass elif options.target != None and options.all: target = options.target if check == True: try: test = open(target, 'r') res = True except: res = False if res == True: targets = open(target, 'r').readlines() for t in targets: t = t.strip() def checker(): try: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t ip = socket.gethostbyname(host) run = socket.create_connection((ip, 80), 2) return True except: pass return False if checker() == True: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t found = [] for address_type in ['A', 'AAAA']: try: answers = dns.resolver.query( host, address_type) for rdata in answers: found.append(rdata) except dns.resolver.NoAnswer: pass le = len(found) if len(found) > 0: print("\n[~]> Target[ {} ]".format(t)) print("[+] Servers Found({}):".format(str(le))) loop = 1 for i in found: print("\tSERVER[{}] > {}".format(loop, i)) loop += 1 print("======================\n") else: print("\n[!] No Servers Found !!!") exit(1) else: pass elif ',' in target: targets = target.split(',') for t in targets: def checker(): try: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t ip = socket.gethostbyname(host) run = socket.create_connection((ip, 80), 2) return True except: pass return False if checker() == True: if t[:8] == "https://": host = t[8:] elif t[:7] == "http://": host = t[7:] else: host = t found = [] for address_type in ['A', 'AAAA']: try: answers = dns.resolver.query( host, address_type) for rdata in answers: found.append(rdata) except dns.resolver.NoAnswer: pass le = len(found) if len(found) > 0: print("\n[~]> Target[ {} ]".format(t)) print("[+] Servers Found({}):".format(str(le))) loop = 1 for i in found: print("\tSERVER[{}] > {}".format(loop, i)) loop += 1 print("======================\n") else: print("\n[!] No Servers Found !!!") exit(1) else: pass else: def checker(): try: if target[:8] == "https://": host = target[8:] elif target[:7] == "http://": host = target[7:] else: host = target ip = socket.gethostbyname(host) run = socket.create_connection((ip, 80), 2) return True except: pass return False if checker() == True: if target[:8] == "https://": host = target[8:] elif target[:7] == "http://": host = target[7:] else: host = target found = [] print("[#]~[Finding Servers IP Of TARGET[ {} ].....\n". format(target)) for address_type in ['A', 'AAAA']: try: answers = dns.resolver.query(host, address_type) for rdata in answers: found.append(rdata) except dns.resolver.NoAnswer: pass le = len(found) if len(found) > 0: print("[@]~[Found [ {} ] Server(s) Status> UP ".format( str(le))) print("[+] Servers:\n") loop = 1 for i in found: print("SERVER[{}] > {}".format(loop, i)) loop += 1 else: print("\n[!] No Servers Found !!!") exit(1) else: print("\n[!] CodeError:404 >> No Server Found !!!") exit(1) else: print("[!] Please Check Your Internet Connection !!!") exit(1) elif options.fme: print("\n[@]~[Finding Your IPs....\n") locipe = locip() if locipe != "[!] Error Your Not Connect To Any Network !!!\n[!] Please Check Your Connection!": print("[L] Local IP: {}".format(locipe)) else: print(" ") print(locipe) exit(1) pupip() elif options.network: ips_list = map_network() if ips_list != False: se(1) loop = 1 up = "UP" print("======================================") print("ID\t\tIP\t\tSTATUS") print("==\t\t==\t\t======") for ip in ips_list: print("{}\t {} \t {}".format(loop, ip, copy(up))) loop += 1 result = loop - 1 print("\nI Found <{}> Device In Network !".format(result)) else: print( "[!] Error Your Not Connect To Any Network !!!\n[!] Please Check Your Connection!" ) exit(1) elif options.ve: print("\n[>] Version>> 1.0\nWait New Version Soon :)") exit(1) elif options.ex: sy("printf '\e[8;70;180;t' || mode 800") sy("clear || cls") examp() exit(1) elif options.check != None: sp = options.check serpor(sp) exit(1) else: print(parse.usage) exit(1)
except KeyboardInterrupt: print("[!] Something Went Wrong!\n[>] Please Try Again :)") exit(1) except ImportError, e: e = e[0][16:] if e == "json": e = "simplejson" elif e == "dns.resolver": e = "dnspython" print( "[!] Error: [" + e + "] Module Is Missing !!!\n[*] Please Install It Using This Command: pip install " + e) exit(1) sy("cls||clear") from Core.examples import examp ## Check Internet Connection..... server = "www.google.com" def check(): try: ip = socket.gethostbyname(server) con = socket.create_connection return True except KeyboardInterrupt: print("[!] Something Went Wrong!\n[>] Please Try Aagain :)") exit(1) except: pass
#!/data/data/com.termux/files/usr/bin/python3 from os import system as sy try: import psutil except Exception: sy("pip3 install psutil") import psutil import platform def conv(bytes, suffix="B"): fact = 1024 for unit in ["", "K", "M", "G", "T", "P"]: if bytes < fact: return f"{bytes:.2f}{unit}{suffix}" bytes /= fact inf = platform.uname() mem = psutil.virtual_memory() frq = psutil.cpu_freq() if inf.system == "Windows": sy("cls") elif inf.system == "Linux": sy("clear") #print("\033[33;1m=\033[m"*32) print(" ", f"\033[37;1m• System: \033[34;1m{inf.system}\033[m") print(" ", f"\033[37;1m• System version: \033[36;1m{inf.release}\033[m") print(" ", f"\033[37;1m• Architecture: \033[35m{inf.machine}\033[m") print( " ",
def main(): sy('clear') global DATE global Map global Map0 print('图表状态:%s' % ('关' if not Map0 else '开')) if input('如需切换请输入1:(默认请直接回车)'): Map0 = int(not Map0) save() sy('clear') timelist = (1, 2, 4, 7, 15, 31, 36, 41) DATE = [] now = datetime.date.today() #今天的日期 if Map[-1][0] != str(now): Map = Map[1:] + [[str(now), 0, 0]] DATE.append(str(now)) for i in timelist: #计算需要复习的日期 delta = datetime.timedelta(days=i) DATE.append(str(now + delta)) L_D = [int(i) for i in daka['L_D'].split('-')] LD = datetime.date(L_D[0], L_D[1], L_D[2]) if (LD + datetime.timedelta(1)) != now and LD != now: daka['CON'] = 0 #没有连续复习 if daka['TOT'] == 0: pass elif not print( f"你已连续复习{daka['CON']}天,累计{daka['TOT']}天啦") and daka['CON'] == 0: print('不积跬步,无以至千里!') elif daka['CON'] < 6: print('继续加油哦!') elif daka['CON'] < 50: print('Whatever is worth doing is worth doing well!') else: print('Great minds have purpose, others have wishes.') #以上初始化结束 while 1: print('\n1.新增 2.复习 3.删除 4.查询 5.退出') try: n = int(input()) except: sy('clear') print('请输入数字!') continue if n == 1: Ch = {} #重复列表 print('新增内容:(q/结束)(格式:A B)(2个空格)') x = input('1.批量导入 2.文件导入:') if x == '2': print('文件内容格式:\nA B\nA B\n...') data = input('输入文件详细地址:\n') try: while data[-1] == ' ': #去除多余空格 data = data[:-1] with open(data, 'r') as f: words = f.read().split('\n') while words[-1] == '': #去除空元素 words = words[:-1] for i in words: print(i) Ch.update(learn(i)) except: print('无法读取文件') elif x == '1': while True: x = input() if x == 'q': break elif x == '': print('无效内容') else: temp = learn(x) if temp: Ch.update(temp) if Ch: #有重复 Change(Ch) elif n == 2: print('复习:(q/退出;y/已会(不再出现);n/不记得(刷新复习频率))') check(str(now)) elif n == 3: for i in wordslist: for k in wordslist[i]: print(k + ' ', end='') print('\n删除:') dele(input()) elif n == 4: seekword() elif n == 5: break input('回车结束...') sy('clear')
from os import system as sy import time, sys sy('clear') red = '\u001b[31m' grn = '\u001b[32m' cyn = '\u001b[36m' re = '\u001b[0m' def an(txt): for t in txt: sys.stdout.write(t) sys.stdout.flush() time.sleep(0.05) banner = ''' Y88b d88P d8888 888b d888 .d8888b. 8888888888 Y88b d88P d8P888 8888b d8888 d88P Y88b 888 Y88o88P d8P 888 88888b.d88888 Y88b. 888 Y888P d8P 888 888Y88888P888 "Y888b. 8888888 d888b d88 888 888 Y888P 888 "Y88b. 888 d88888b 8888888888 888 Y8P 888 "888 888 d88P Y88b 888 888 " 888 Y88b d88P 888 d88P Y88b 888 888 888 "Y8888P" 888 ''' print(red + banner + re) an(grn + 'A Metasploit Framework Payload Creator!!!\n' + re)
def __init__(self): sy('clear') print('FOTOSSÍNTESE')
#!/usr/bin/env python # Created By Benelhaj_younes #Libraries# try: from os import system as sy, path import requests, socket, optparse sy("") except ImportError: print(unknown2 + "Error Please Install [Requests] Module !!!") print(unknown6 + "Use This Command > pip install requests") exit(1) # Check Internet Connection # def cnet(): try: ip = socket.gethostbyname("www.google.com") con = socket.create_connection((ip, 80), 2) return True except socket.error: pass return False #Check-Email-Function# # def Friend(email): try: