/*        attempt at sending characters to the printer.	*/
#include "stdio.h"

main()
	{
		char in_name[15];
		FILE *read_file, *out_file, *fopen ();
		int c;

		printf("enter name of file to be printed : ");
		scanf ("%.14s", &in_name);
		read_file = fopen (in_name, "r");

		if ( read_file == NULL )
			printf("couldn't open %s for reading.\n",in_name);
		else
			{
				out_file = fopen ("prn:" , "w");
					if (out_file == NULL )
						Printf("xcheck printer.\n");
					else
                    {
						while ( (c = getc(read_file)) != EOF )
							putc (c, out_file);

						printf("file has been PRINTED!\n");

						}
				}
					out_file = fclose("prn:");
					read_file= fclose(in_name);

	}
	
                                 