#!/usr/bin/perl

while (<>) {
        print "\{";
        s/,/\},\{/g;
        s/\n/\}\n/g;
        print;
}