Though select returns three elements, your code is only using the first one, $sets, a reference to an array of handles ready for reading. To de-reference this array reference $sets, you use @$sets, as described in the perlreftut link already provided by toolic. Note that @$sets is equivalent to @{$sets} (the form more commonly used in perlreftut). You need to take the time to read perlreftut and to understand how references work in Perl.
In reply to Re^3: @$ variable type
by eyepopslikeamosquito
in thread @$ variable type
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |