| JuggaloAnt | last i checked it was just $y |
| ofer | JuggaloAnt, for$x(2..97){$y=0;for(2..$x){($_!=$x&&!($x%$_))&&($y=1)}$y||print"$x is prime.\n"} 82 bytes |
| revdiablo | for$x(2..97){$y=0;$_!=$x&&!($x%$_)&&($y=1) for 2..$x;$y||print"$x is prime.\n";} ofer: Nice, GMTA |
| ofer | revdiablo, :) |
| revdiablo | Mine's 80 |
| ofer | yeap |
| pkundu | hi ca anybody guide me where can I find perl scripts for controlling system. I am not talking of CGI scripts. Thanks *can |
| JuggaloAnt | revdiablo: wont that always be 1? err. nevermind. the after for always messes me up |
| cfedde | pkundu: what kind of control? |
| ofer | 78 bytes! |
| pkundu | any system control or non cgi scripts. Particularly Networking scripts |
| ofer | for$x(2..97){$y=0;$_!=$x&&!($x%$_)&&($y=1)for 2..$x;$y||print"$x is prime.\n"} |
| jql | conventional prime number validation is so passe |
| revdiablo | for$x(2..97){$y=0;$y|=($_!=$x&&!($x%$_)) for 2..$x;$y||print"$x is prime.\n"} |
| hmm-home | ok what is the difference between open(FH, 'myfile') and open(my $fh, 'myfile'); ? |
| revdiablo | 77 =) |
| ofer | hmm-home, FH is global |
| buu | HELLO |
| hmm-home | and $fh is not |
| JuggaloAnt | revdiablo: whats |= ? |
| ofer | JuggaloAnt, perldoc perlop |
| hmm-home | then that doesn't make sense as to why this isn't working |
| ofer | hmm-home, show code. |
| revdiablo | JuggaloAnt: or-assignment |
| jql | doesn't anyone cheat at golf anymore? |
| action | jql sighs |
| jql | sighs |
| revdiablo | The whole point is to cheat I don't see your entry ;) |
| jql | (1 x$_)!~/^1?$|^(11+?)\1+$/&&print"$_ is prime.\n"for 2..97 there |
| action | jql stoled it |
| jql | stoled it |
| Perlmongler | in activeperl, how do you open a device, where are window devices listed? |
| pasteling | "hmm-home" at 24.117.131.41 pasted "#This works open(TTY, "+</dev/" (9 lines, 214B) at http://sial.org/pbot/24412 |
| hmm-home | $ttythere |