title: Python Regex to look for ALL special characters in a keyboard
body: <p>I want to iterate through a dataframe (cell by cell) and check if it contains ANY special character in it. I'm unable to look for special characters like - period, square brackets, etc</p>
  <pre><code>#reading csv file into a df
  df = pd.read_csv(data, sep=',', header='infer',encoding='latin1')
  
  #empty lists
  list1=[]
  list2=[]
  
  #regular expression for all special characters
  regex = re.compile('[@_!#$%^&amp;*()&lt;&gt;;,.?/\|}{~:]')
  
  #iterating through all columns of the df
  for col in df.columns:
  #getting number of rows in the df
      countx=len(df)
      county=0
      for i in df[col]:
          if type(i)==str:
  
  #if no special characters are found in the cell, subtracting 1 from countx
              if(regex.search(str(i)) == None):
                  countx=countx-1
  
  #if special characters are found in the value, adding 1 to county
              else: 
                  county=county+1
                  list2.append(i)
      if countx != 0 and county&gt;0:
          list1.append(col)
  </code></pre>
  <p>Now, when I'm printing 'list1', I'm not getting columns that have certain special characters like - periods(.), square bracket([), etc.</p>
  <p>Can someone help me with regex to look for ALL special characters present in a keyboard? Thanks!</p>