with open("record_types.txt", "r") as f:
    data = f.read()

GROUPING = 6
PREFIX = "RT_"
line = []
out = ""
for i, l in enumerate(data.split("\n")):
    word = l.strip()
    line += [f"{PREFIX}{word}"]

    if (i + 1) % GROUPING == 0:
        out += ", ".join(line) + ",\n"
        line = []

if line:
    out += ", ".join(line) + ",\n"

print(out)
