title: what is the difference b/w [1:] and lines[1:] in python?
body: <p>Please explain to me the lines commented below :</p>
  
  <pre><code>def readfile(filename):
      lines = [line for line in file(filename)]
      cols = lines[0].strip().split('\t')[1:] #why [1:] here? what is it doing?
      rows = [] #whats the difference between rows = [] and rows = {}
      data=[]
      for line in lines[1:]: #what lines[1:] is doing?
          p=line.strip().split('\t')
          rows.append(p[0])
          #why we used float below if my file contains only integer numbers?
          data.append([float(x) for x in p[1:]])    
      return rows,cols,data
  </code></pre>