Perl simple file writing script

Try the following:

open FIL,">temp";
print FIL "Hola";
print FIL "Nada";
close FIL; 

Note:
No commas are allowed after the file handle, before the string to be written. Line breaks are not inserted unless specified.

open FIL,">temp";
print FIL "Hola";
print FIL "Nada";
close FIL;