#!/usr/bin/perl # split() uses pattern matching, too # simple example of a pattern $breakfast = "ham,eggs,cereal,grits"; @items = split(/,/, $breakfast); foreach $item(@items) { print "$item\n"; } # ham # eggs # cereal # grits