Anyone any ideas why this while loop wont work?
while (open(MYFILE, "$filename") == 0) { printf("Cannot open file for reading"); printf("\n\nDo you wish to enter a new file?: "); $choice = <>; if ($choice eq "no") { die("Program ending"); } if ($choice eq "yes") { print("Enter the name of the file you wish to print: "); $filename = <>; } }
In reply to While loop wont work by newtoperl1993
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |