stdout with lots of blocks of text that look something like this:
% QUESTION Who played drums for The Beatles? % QUESTION Who played guitar for The Beatles? % QUESTION Who played bass for The Beatles ?
The idea here is that the file is divided into "chunks" where each chunk begins with the line
% QUESTION. I'd like to write a script that will print the nth chunk of this data.
For example, issuing
nthchunk 3 should print
Who played bass for The Beatles ?
How could I go about doing this?