def get_rows_and_header(items):
    """
     Return rows and header to print using tabulate.

     :param items: list of dicts
     :return: rows are all values in items. header is keys of dict

     Example:
     If items is a list of vpc dicts:
     [
         {"id":vpc-id1, "name":name1, "number_of_subnets": 6},
         {"id":vpc-id2, "name":name2, "number_of_subnets": 1}
         {"id":vpc-id3, "name":name2, "number_of_subnets": 2}
     ]
     Return is:
      (
         [
             [1, vpc-id1, name1, 6],
             [2, vpc-id2, name2, 1],
             [3, vpc-id3, name3, 2]
         ],
         ["#", "id", "name", "number_of_subnets"]
      )
     Finally, tabulate(rows header) prints:
      #  id         name       number_of_subnets
    ---  --------  ---------  -------------------
      1  vpc-id1    name1                    6
      2  vpc-id2    name2                    1
      3  vpc-id3    name3                    2
    """
    header = list(items[0].keys())
    header.insert(0, "#")
    rows = []
    for iterator, item in enumerate(items, start=1):
        row = list(item.values())
        row.insert(0, str(iterator))
        rows.append(row)
    return rows, header