title: How to find column of same values in csv file using python
body: <p>I have a csv file test.csv. It have 5000 columns. Some of columns (example 50 columns), have same value in all rows. How can I find how many column have same value and print those columns in separate csv.
  Example,</p>
  
  <pre><code>A B C D
  1 2 2 3
  1 2 3 3
  1 2 4 3
  1 2 5 3
  1 2 7 3
  </code></pre>
  
  <p>I want to find columns which have similar values/elements such as A,B and D . Then print those A,B and D in separate CSV file and C in separate CSV.</p>
  
  <p>Thank you.</p>