Output n line from each rule extracted