mfx28

X3

Jun 9th, 2019
163
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.46 KB | None | 0 0
  1. #Regra X3 - Não pode usar caracteres fora do set [a-z A-Z 0-9 ' '] + [! # - * + & % @ _]
  2. def naousar_foradoset(input):
  3.     foradoset = 0
  4.     lista_set = "a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 1 2 3 4 5 6 7 8 9 0 ' ' ! # - * + & % @ _".split()
  5.     for char in input:
  6.         if char in lista_set:
  7.             foradoset += 1
  8.     if foradoset >= 1:
  9.         return True
  10.     else:
  11.         return False
Advertisement
Add Comment
Please, Sign In to add comment