format UHLY_TOP =
Stanovisko   Lavy ciel   Pravy ciel   Merany uhol 
----------   ----------  ---------    -------------  
.
format UHLY =
@<<<<<<<<     @<<<<<<<<   @<<<<<<<<  @####.####  
$stanovisko, $lavy_ciel, $pravy_ciel, $merany_uhol
.
open(SUBOR, "<uhly.txt");
@uhly = <SUBOR>;
close SUBOR;
open(UHLY, ">>pokus.txt"); 
                                       

foreach (@uhly) {                                            
  chop;                                                       
  ($stanovisko, $lavy_ciel, $pravy_ciel, $merany_uhol) = (split(/ /));                   
                         
  write(UHLY);    
}
close(UHLY);  

foreach (@uhly){
	chop;
if ($stanovisko == 21 and $lavy_ciel == 22 and $pravy_ciel == 23) {
		print $merany_uhol;
		}
		else {
		print "uhol nebol merany\n";
		}
	}
	

