#!/usr/bin/perl use strict; use warnings; open(FIFO, "> age-pipe") or die $!; select FIFO; $|=1; select STDOUT;$|=1; my $input = 'a'; while(1){ print "Enter your age:\n"; #my $input = ; print FIFO "$input\n"; sleep(1); $input++ } close(FIFO);