code: def analyse(self, path_and_filename, pattern):
          
          with open(path_and_filename) as handle:
              content = handle.read()
              loc = content.count('\n') + 1
              com = 0
              for match in re.findall(pattern, content, re.DOTALL):
                  com += match.count('\n') + 1
  
              return max(0, loc - com), com
docs: Find out lines of code and lines of comments.
  
          Args:
              path_and_filename (str): path and filename to parse  for loc and com.
              pattern (str): regex to search for line commens and block comments
  
          Returns:
              int, int: loc and com for given file.