Regarding the "here document," I was wondering if there was an equivalent way to do this in a high-level language like Java? I haven't been successful finding anything as of yet. I have included an example of a Perl script here document below:
You will be prompted for your name and other information. Please give complete answers to each question. To return to the menu without making an entry type q [Enter].
This output everything between the EOHeader tags without having to use four or five print commands.