#!/usr/bin/env python3

import csv
import sys

delimiter = sys.argv[1] if len(sys.argv) == 2 else "\t"

print(f"'{delimiter}'")

rows = list(csv.reader(sys.stdin, delimiter=delimiter))
writer = csv.writer(sys.stdout, delimiter="|")
for col in range(0, len(rows[0])):
    writer.writerow([f"{col + 1}. "] + [row[col] for row in rows])
