From Ganesh.Shankar at RoswellPark.org Wed Sep 1 07:55:40 2004 From: Ganesh.Shankar at RoswellPark.org (Shankar, Ganesh) Date: Wed Sep 1 07:55:43 2004 Subject: [Buffalo-pm] Where to post perl programming question? Message-ID: <6FF91AE4F1DC7743A6466E334EB865AE02E64425@VERITY.roswellpark.org> Hello all, I apologize if this is the wrong forum. I'm new to perl and need some help with a syntax error that I'm getting. Can anyone point me to the right forum? Thanks, Ganesh From cbrandt at buffalo.edu Wed Sep 1 09:18:31 2004 From: cbrandt at buffalo.edu (Jim Brandt) Date: Wed Sep 1 09:18:34 2004 Subject: [Buffalo-pm] Where to post perl programming question? In-Reply-To: <6FF91AE4F1DC7743A6466E334EB865AE02E64425@VERITY.roswellpark.org> References: <6FF91AE4F1DC7743A6466E334EB865AE02E64425@VERITY.roswellpark.org> Message-ID: This forum is fine. Fire away and we'll see if we can help! Jim On Sep 1, 2004, at 8:55 AM, Shankar, Ganesh wrote: > Hello all, > I apologize if this is the wrong forum. I'm new to perl and need some > help with a syntax error that I'm getting. Can anyone point me to the > right forum? > > Thanks, > Ganesh > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm > ========================================== Jim Brandt Administrative Computing Services University at Buffalo From Ganesh.Shankar at RoswellPark.org Wed Sep 1 10:37:11 2004 From: Ganesh.Shankar at RoswellPark.org (Shankar, Ganesh) Date: Wed Sep 1 10:37:15 2004 Subject: [Buffalo-pm] Syntax error at hash assignment. Message-ID: <6FF91AE4F1DC7743A6466E334EB865AE02EB0173@VERITY.roswellpark.org> I'm new to perl and learning by running examples. I'm using a script from Programming Perl, 2nd edition, 2nd chapter. There's a script involving getting the average grades of students (http://www.oreilly.com/catalog/pperl2/excerpt/ch01.html#PERL2-CH-1-SECT-3). Essentially students are listed in the first column and their scores are listed in the second column. The student can be listed multiple times in the first column. The script should gather all the scores for each student and average them. Then print out the student's name once and their corresponding average. I have to do something analogous in my microarray data analysis. I copied the script, added strict and warning, assigned scope to the variables and ran into a syntax problem on this line: my $grades{$student} .= $grade . " ";. I'm trying to figure out how the program works but I can't see the syntax error. Thanks for any help. #!/usr/bin/perl use strict; use warnings; open( GRADES, "grades" ) or die "Can't open grades: $!\n"; while ( my $line = ) { ( my $student, my $grade ) = split( '\t', $line ); my $grades{$student} .= $grade . " "; } foreach $student ( sort keys my %grades ) { my $scores = 0; my $total = 0; my @grades = split( '\t', $grades{$student} ); foreach $grade (@grades) { $total += $grade; $scores++; } my $average = $total / $scores; print "$student: $grades{$student}\t Average: $average\n"; } From eye at buffalo.edu Wed Sep 1 10:59:22 2004 From: eye at buffalo.edu (Kevin Eye) Date: Wed Sep 1 10:59:25 2004 Subject: [Buffalo-pm] Syntax error at hash assignment. In-Reply-To: <6FF91AE4F1DC7743A6466E334EB865AE02EB0173@VERITY.roswellpark.org> References: <6FF91AE4F1DC7743A6466E334EB865AE02EB0173@VERITY.roswellpark.org> Message-ID: I believe the problem is your use of "my" on that line. You need to use "my" to declare the entire hash, but not to declare each key of the hash. You also don't want the "my" on the foreach line. So change it to something like this: ... open( GRADES, "grades" ) or die "Can't open grades: $!\n"; my %grades; while ( my $line = ) { ( my $student, my $grade ) = split( '\t', $line ); $grades{$student} .= $grade . " "; } foreach $student ( sort keys %grades ) { ... - Kevin On Sep 1, 2004, at 11:37 AM, Shankar, Ganesh wrote: > I'm new to perl and learning by running examples. I'm using a script > from Programming Perl, 2nd edition, 2nd chapter. There's a script > involving getting the average grades of students > (http://www.oreilly.com/catalog/pperl2/excerpt/ch01.html#PERL2-CH-1- > SECT-3). > Essentially students are listed in the first column and their scores > are listed in the second column. The student can be listed multiple > times in the first column. The script should gather all the scores for > each student and average them. Then print out the student's name once > and their corresponding average. > > I have to do something analogous in my microarray data analysis. I > copied the script, added strict and warning, assigned scope to the > variables and ran into a syntax problem on this line: my > $grades{$student} .= $grade . " ";. I'm trying to figure out how the > program works but I can't see the syntax error. > > Thanks for any help. > > > > #!/usr/bin/perl > use strict; > use warnings; > > open( GRADES, "grades" ) or die "Can't open grades: $!\n"; > while ( my $line = ) { > ( my $student, my $grade ) = split( '\t', $line ); > my $grades{$student} .= $grade . " "; > } > > foreach $student ( sort keys my %grades ) { > my $scores = 0; > my $total = 0; > my @grades = split( '\t', $grades{$student} ); > foreach $grade (@grades) { > $total += $grade; > $scores++; > } > my $average = $total / $scores; > print "$student: $grades{$student}\t Average: $average\n"; > } > > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm > -- Kevin Eye Web Applications Developer Creative Services and Marketing University at Buffalo 330 Crofts Hall Buffalo, NY 14260 eye@buffalo.edu phone (716) 645-5000 x1435 fax (716) 645-3765 From dmagnuszewski at yahoo.com Wed Sep 1 13:37:27 2004 From: dmagnuszewski at yahoo.com (Daniel Magnuszewski) Date: Wed Sep 1 13:37:30 2004 Subject: [Buffalo-pm] Syntax error at hash assignment. In-Reply-To: <6FF91AE4F1DC7743A6466E334EB865AE02EB0173@VERITY.roswellpark.org> Message-ID: <20040901183727.53442.qmail@web21123.mail.yahoo.com> Perhaps providing an example file would help too - assuming Kevin's resolution does not fix your error completely. Either way, here's a little hint to help keep your code a bit "cleaner". On the line: ( my $student, my $grade ) = split( '\t', $line ); You can change it to: my ($student, $grade) = split( '\t', $line ); It may not seem like much of a difference in this example, but IMHO when you start having more variables, your lines of code could get long and ugly looking. ...I know, I know...it's petty ;-) -Dan "Shankar, Ganesh" wrote: I'm new to perl and learning by running examples. I'm using a script from Programming Perl, 2nd edition, 2nd chapter. There's a script involving getting the average grades of students (http://www.oreilly.com/catalog/pperl2/excerpt/ch01.html#PERL2-CH-1-SECT-3). Essentially students are listed in the first column and their scores are listed in the second column. The student can be listed multiple times in the first column. The script should gather all the scores for each student and average them. Then print out the student's name once and their corresponding average. I have to do something analogous in my microarray data analysis. I copied the script, added strict and warning, assigned scope to the variables and ran into a syntax problem on this line: my $grades{$student} .= $grade . " ";. I'm trying to figure out how the program works but I can't see the syntax error. Thanks for any help. #!/usr/bin/perl use strict; use warnings; open( GRADES, "grades" ) or die "Can't open grades: $!\n"; while ( my $line = ) { ( my $student, my $grade ) = split( '\t', $line ); my $grades{$student} .= $grade . " "; } foreach $student ( sort keys my %grades ) { my $scores = 0; my $total = 0; my @grades = split( '\t', $grades{$student} ); foreach $grade (@grades) { $total += $grade; $scores++; } my $average = $total / $scores; print "$student: $grades{$student}\t Average: $average\n"; } _______________________________________________ Buffalo-pm mailing list Buffalo-pm@mail.pm.org http://mail.pm.org/mailman/listinfo/buffalo-pm --------------------------------- Do you Yahoo!? Win 1 of 4,000 free domain names from Yahoo! Enter now. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/buffalo-pm/attachments/20040901/7a2adb7f/attachment.htm From jkeen at verizon.net Wed Sep 1 17:08:35 2004 From: jkeen at verizon.net (James Keenan) Date: Wed Sep 1 17:07:44 2004 Subject: [Buffalo-pm] Where to post perl programming question? In-Reply-To: <200409011700.i81H0Mtw022274@www.pm.org> References: <200409011700.i81H0Mtw022274@www.pm.org> Message-ID: <784473FA-FC63-11D8-A79F-000D932B9CD4@verizon.net> On Sep 1, 2004, "Shankar, Ganesh" wrote: > I'm new to perl and learning by running examples. I'm using a script > from Programming Perl, 2nd edition, 2nd chapter. While it *is* possible to teach yourself Perl from Programming Perl (a.k.a. the "Camel book"), you should understand: (a) you're not using the most recent edition (although the differences between the 2nd and 3rd editions are probably few from the point of view of a beginner), and (more importantly), (b) while the Camel book is the standard reference work on the language, other books are more focused on enabling you to *learn* Perl. The most frequent recommendations: "Learning Perl" (3rd ed.) by Randal L Schwartz and Tom Phoenix (a.k.a. the "Llama book"); "Effective Perl Programming" by Joseph N Hall and Randal L Schwartz; and "Elements of Programming with Perl" by Andrew L Johnson. I worked my way through the Llama book when I was first learning Perl, and then I turned around and assigned it as a textbook when I was teaching an introductory level course. Jim Keenan From jasonp at panix.com Wed Sep 1 21:18:38 2004 From: jasonp at panix.com (Jason Parker-Burlingham) Date: Wed Sep 1 21:18:45 2004 Subject: [Buffalo-pm] Where to post perl programming question? In-Reply-To: <784473FA-FC63-11D8-A79F-000D932B9CD4@verizon.net> (James Keenan's message of "Wed, 1 Sep 2004 18:08:35 -0400") References: <200409011700.i81H0Mtw022274@www.pm.org> <784473FA-FC63-11D8-A79F-000D932B9CD4@verizon.net> Message-ID: <87sma1l8g1.fsf@freezer.burling> James Keenan writes: > While it *is* possible to teach yourself Perl from Programming Perl > (a.k.a. the "Camel book"), you should understand: > (b) while the Camel book is the standard reference work on the > language, other books are more focused on enabling you to *learn* > Perl. I would add also Damian Conway's wonderful "Object Oriented Perl", from Hanning. jason From Ganesh.Shankar at RoswellPark.org Thu Sep 2 16:18:56 2004 From: Ganesh.Shankar at RoswellPark.org (Shankar, Ganesh) Date: Thu Sep 2 16:18:59 2004 Subject: [Buffalo-pm] Learning Perl Message-ID: <6FF91AE4F1DC7743A6466E334EB865AE02EB0174@VERITY.roswellpark.org> Two items. One: The proposed solution to my syntax error was the correct one and after a couple of other changes, the program did what I wanted. So, thanks to all who replied. Two: I'm learning perl from the "Beginning Perl for Bioinformatics" book with tadpoles on the cover. The examples in the book are close to the problems I face with data analysis. I read, get the idea, code for my problem, run, fix compile problems. When, I'm stuck, I google the error message and usually get some relevant hits. So, my knowledge is very spotty. This was the first time I used hashes, for example. Now that I know about them, I can see how I need to use them to store information needed in different parts of the program. I'm totally non-partisan about my pedagogical sources. Again, thanks to everyone. -Ganesh -----Original Message----- From: buffalo-pm-bounces@mail.pm.org [mailto:buffalo-pm-bounces@mail.pm.org]On Behalf Of buffalo-pm-request@mail.pm.org Sent: Thursday, September 02, 2004 1:00 PM To: buffalo-pm@mail.pm.org Subject: Buffalo-pm Digest, Vol 15, Issue 2 Send Buffalo-pm mailing list submissions to buffalo-pm@mail.pm.org To subscribe or unsubscribe via the World Wide Web, visit http://mail.pm.org/mailman/listinfo/buffalo-pm or, via email, send a message with subject or body 'help' to buffalo-pm-request@mail.pm.org You can reach the person managing the list at buffalo-pm-owner@mail.pm.org When replying, please edit your Subject line so it is more specific than "Re: Contents of Buffalo-pm digest..." Today's Topics: 1. Re: Syntax error at hash assignment. (Daniel Magnuszewski) 2. Where to post perl programming question? (James Keenan) 3. Re: Where to post perl programming question? (Jason Parker-Burlingham) ---------------------------------------------------------------------- Message: 1 Date: Wed, 1 Sep 2004 11:37:27 -0700 (PDT) From: Daniel Magnuszewski Subject: Re: [Buffalo-pm] Syntax error at hash assignment. To: "Shankar, Ganesh" , buffalo-pm@mail.pm.org Message-ID: <20040901183727.53442.qmail@web21123.mail.yahoo.com> Content-Type: text/plain; charset="us-ascii" Perhaps providing an example file would help too - assuming Kevin's resolution does not fix your error completely. Either way, here's a little hint to help keep your code a bit "cleaner". On the line: ( my $student, my $grade ) = split( '\t', $line ); You can change it to: my ($student, $grade) = split( '\t', $line ); It may not seem like much of a difference in this example, but IMHO when you start having more variables, your lines of code could get long and ugly looking. ...I know, I know...it's petty ;-) -Dan "Shankar, Ganesh" wrote: I'm new to perl and learning by running examples. I'm using a script from Programming Perl, 2nd edition, 2nd chapter. There's a script involving getting the average grades of students (http://www.oreilly.com/catalog/pperl2/excerpt/ch01.html#PERL2-CH-1-SECT-3). Essentially students are listed in the first column and their scores are listed in the second column. The student can be listed multiple times in the first column. The script should gather all the scores for each student and average them. Then print out the student's name once and their corresponding average. I have to do something analogous in my microarray data analysis. I copied the script, added strict and warning, assigned scope to the variables and ran into a syntax problem on this line: my $grades{$student} .= $grade . " ";. I'm trying to figure out how the program works but I can't see the syntax error. Thanks for any help. #!/usr/bin/perl use strict; use warnings; open( GRADES, "grades" ) or die "Can't open grades: $!\n"; while ( my $line = ) { ( my $student, my $grade ) = split( '\t', $line ); my $grades{$student} .= $grade . " "; } foreach $student ( sort keys my %grades ) { my $scores = 0; my $total = 0; my @grades = split( '\t', $grades{$student} ); foreach $grade (@grades) { $total += $grade; $scores++; } my $average = $total / $scores; print "$student: $grades{$student}\t Average: $average\n"; } _______________________________________________ Buffalo-pm mailing list Buffalo-pm@mail.pm.org http://mail.pm.org/mailman/listinfo/buffalo-pm --------------------------------- Do you Yahoo!? Win 1 of 4,000 free domain names from Yahoo! Enter now. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/archives/buffalo-pm/attachments/20040901/7a2adb7f/attachment-0001.htm ------------------------------ Message: 2 Date: Wed, 1 Sep 2004 18:08:35 -0400 From: James Keenan Subject: [Buffalo-pm] Where to post perl programming question? To: buffalo-pm@mail.pm.org Message-ID: <784473FA-FC63-11D8-A79F-000D932B9CD4@verizon.net> Content-Type: text/plain; charset=US-ASCII; format=flowed On Sep 1, 2004, "Shankar, Ganesh" wrote: > I'm new to perl and learning by running examples. I'm using a script > from Programming Perl, 2nd edition, 2nd chapter. While it *is* possible to teach yourself Perl from Programming Perl (a.k.a. the "Camel book"), you should understand: (a) you're not using the most recent edition (although the differences between the 2nd and 3rd editions are probably few from the point of view of a beginner), and (more importantly), (b) while the Camel book is the standard reference work on the language, other books are more focused on enabling you to *learn* Perl. The most frequent recommendations: "Learning Perl" (3rd ed.) by Randal L Schwartz and Tom Phoenix (a.k.a. the "Llama book"); "Effective Perl Programming" by Joseph N Hall and Randal L Schwartz; and "Elements of Programming with Perl" by Andrew L Johnson. I worked my way through the Llama book when I was first learning Perl, and then I turned around and assigned it as a textbook when I was teaching an introductory level course. Jim Keenan ------------------------------ Message: 3 Date: Wed, 01 Sep 2004 22:18:38 -0400 From: Jason Parker-Burlingham Subject: Re: [Buffalo-pm] Where to post perl programming question? To: buffalo-pm@mail.pm.org Message-ID: <87sma1l8g1.fsf@freezer.burling> Content-Type: text/plain; charset=us-ascii James Keenan writes: > While it *is* possible to teach yourself Perl from Programming Perl > (a.k.a. the "Camel book"), you should understand: > (b) while the Camel book is the standard reference work on the > language, other books are more focused on enabling you to *learn* > Perl. I would add also Damian Conway's wonderful "Object Oriented Perl", from Hanning. jason ------------------------------ _______________________________________________ Buffalo-pm mailing list Buffalo-pm@mail.pm.org http://mail.pm.org/mailman/listinfo/buffalo-pm End of Buffalo-pm Digest, Vol 15, Issue 2 ***************************************** From sgriffit at gennum.com Thu Sep 2 17:04:51 2004 From: sgriffit at gennum.com (Shaun Griffith) Date: Thu Sep 2 16:59:51 2004 Subject: [Buffalo-pm] Learning Perl In-Reply-To: <6FF91AE4F1DC7743A6466E334EB865AE02EB0174@VERITY.roswellpark.org> Message-ID: <007001c49138$df2d71b0$c417005a@PC647> Ganesh Shankar wrote: > When, I'm stuck, I google the error message and usually get some relevant hits. use diagnostics; is sometimes helpful, giving out expanded info on error messages. These are also a must: use strict; use warnings; [Some will complain, but if you don't know why to turn them off, and where, then you probably shouldn't.] Line numbers in error messages are rough guesses. Sometimes the real error is before or after (could be many lines away, depending on the structures involved). Sometimes the error message is misleading, and you're really missing a closing paren/brace/bracket, or semicolon. [My most frequent error seems to be: syntax error at q.pl line 5, near "my " Global symbol "$y" requires explicit package name at q.pl line 5. which is caused by "my $x = 1" not having a semicolon, but is immediately followed by "my $y = 2;"] The command line debugger (perl -d scriptname) is a powerful tool. Use it to verify that you are getting the behavior you expect (variables, flow control). Or you can use ptkdb, the Perl/Tk visual debugger. From cbrandt at buffalo.edu Fri Sep 3 07:05:13 2004 From: cbrandt at buffalo.edu (Jim Brandt) Date: Fri Sep 3 07:05:12 2004 Subject: [Buffalo-pm] Learning Perl In-Reply-To: <6FF91AE4F1DC7743A6466E334EB865AE02EB0174@VERITY.roswellpark.org> References: <6FF91AE4F1DC7743A6466E334EB865AE02EB0174@VERITY.roswellpark.org> Message-ID: <830933AF-FDA1-11D8-A819-000A9588183A@buffalo.edu> That's what is great about Perl--low barrier to entry. You can get up and running quickly from just a few examples. Several people have told me they've gone to "Learning Perl" *after* they have been coding for a while in Perl and found that it filled in the gaps. Since there is often more than one way to do it, sometimes you stumble on one way and never learn an easier way. For those of you who have any relationship with UB, we now have access to O'Reilly's Safari service for books (actually, this has been working all summer, but they just announced it). I think they granted access by IP, so this might only work on a campus network, but try these: http://proquest.safaribooksonline.com/?uicode=buffalo http://safari.oreilly.com All the perl books are available, including "Learning Perl." For those of you not affiliated, that alumni fee just got more reasonable... On Sep 2, 2004, at 5:18 PM, Shankar, Ganesh wrote: > Two items. > One: The proposed solution to my syntax error was the correct one and > after a couple of other changes, the program did what I wanted. So, > thanks to all who replied. > > Two: I'm learning perl from the "Beginning Perl for Bioinformatics" > book with tadpoles on the cover. The examples in the book are close > to the problems I face with data analysis. I read, get the idea, code > for my problem, run, fix compile problems. When, I'm stuck, I google > the error message and usually get some relevant hits. So, my > knowledge is very spotty. This was the first time I used hashes, for > example. Now that I know about them, I can see how I need to use them > to store information needed in different parts of the program. I'm > totally non-partisan about my pedagogical sources. > > Again, thanks to everyone. > > -Ganesh > > -----Original Message----- > From: buffalo-pm-bounces@mail.pm.org > [mailto:buffalo-pm-bounces@mail.pm.org]On Behalf Of > buffalo-pm-request@mail.pm.org > Sent: Thursday, September 02, 2004 1:00 PM > To: buffalo-pm@mail.pm.org > Subject: Buffalo-pm Digest, Vol 15, Issue 2 > > > Send Buffalo-pm mailing list submissions to > buffalo-pm@mail.pm.org > > To subscribe or unsubscribe via the World Wide Web, visit > http://mail.pm.org/mailman/listinfo/buffalo-pm > or, via email, send a message with subject or body 'help' to > buffalo-pm-request@mail.pm.org > > You can reach the person managing the list at > buffalo-pm-owner@mail.pm.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Buffalo-pm digest..." > > > Today's Topics: > > 1. Re: Syntax error at hash assignment. (Daniel Magnuszewski) > 2. Where to post perl programming question? (James Keenan) > 3. Re: Where to post perl programming question? > (Jason Parker-Burlingham) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Wed, 1 Sep 2004 11:37:27 -0700 (PDT) > From: Daniel Magnuszewski > Subject: Re: [Buffalo-pm] Syntax error at hash assignment. > To: "Shankar, Ganesh" , > buffalo-pm@mail.pm.org > Message-ID: <20040901183727.53442.qmail@web21123.mail.yahoo.com> > Content-Type: text/plain; charset="us-ascii" > > Perhaps providing an example file would help too - assuming Kevin's > resolution does not fix your error completely. > > Either way, here's a little hint to help keep your code a bit > "cleaner". On the line: > > ( my $student, my $grade ) = split( '\t', $line ); > > You can change it to: > > my ($student, $grade) = split( '\t', $line ); > > It may not seem like much of a difference in this example, but IMHO > when you start having more variables, your lines of code could get > long and ugly looking. > > ...I know, I know...it's petty ;-) > > -Dan > > "Shankar, Ganesh" wrote: > I'm new to perl and learning by running examples. I'm using a script > from Programming Perl, 2nd edition, 2nd chapter. There's a script > involving getting the average grades of students > (http://www.oreilly.com/catalog/pperl2/excerpt/ch01.html#PERL2-CH-1- > SECT-3). > Essentially students are listed in the first column and their scores > are listed in the second column. The student can be listed multiple > times in the first column. The script should gather all the scores for > each student and average them. Then print out the student's name once > and their corresponding average. > > I have to do something analogous in my microarray data analysis. I > copied the script, added strict and warning, assigned scope to the > variables and ran into a syntax problem on this line: my > $grades{$student} .= $grade . " ";. I'm trying to figure out how the > program works but I can't see the syntax error. > > Thanks for any help. > > > > #!/usr/bin/perl > use strict; > use warnings; > > open( GRADES, "grades" ) or die "Can't open grades: $!\n"; > while ( my $line = ) { > ( my $student, my $grade ) = split( '\t', $line ); > my $grades{$student} .= $grade . " "; > } > > foreach $student ( sort keys my %grades ) { > my $scores = 0; > my $total = 0; > my @grades = split( '\t', $grades{$student} ); > foreach $grade (@grades) { > $total += $grade; > $scores++; > } > my $average = $total / $scores; > print "$student: $grades{$student}\t Average: $average\n"; > } > > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm > > > > --------------------------------- > Do you Yahoo!? > Win 1 of 4,000 free domain names from Yahoo! Enter now. > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.pm.org/archives/buffalo-pm/attachments/20040901/7a2adb7f/ > attachment-0001.htm > > ------------------------------ > > Message: 2 > Date: Wed, 1 Sep 2004 18:08:35 -0400 > From: James Keenan > Subject: [Buffalo-pm] Where to post perl programming question? > To: buffalo-pm@mail.pm.org > Message-ID: <784473FA-FC63-11D8-A79F-000D932B9CD4@verizon.net> > Content-Type: text/plain; charset=US-ASCII; format=flowed > > > On Sep 1, 2004, "Shankar, Ganesh" > wrote: > >> I'm new to perl and learning by running examples. I'm using a script >> from Programming Perl, 2nd edition, 2nd chapter. > > While it *is* possible to teach yourself Perl from Programming Perl > (a.k.a. the "Camel book"), you should understand: > (a) you're not using the most recent edition (although the differences > between the 2nd and 3rd editions are probably few from the point of > view of a beginner), and (more importantly), > (b) while the Camel book is the standard reference work on the > language, other books are more focused on enabling you to *learn* Perl. > The most frequent recommendations: "Learning Perl" (3rd ed.) by > Randal L Schwartz and Tom Phoenix (a.k.a. the "Llama book"); "Effective > Perl Programming" by Joseph N Hall and Randal L Schwartz; and "Elements > of Programming with Perl" by Andrew L Johnson. > > I worked my way through the Llama book when I was first learning Perl, > and then I turned around and assigned it as a textbook when I was > teaching an introductory level course. > > Jim Keenan > > > > ------------------------------ > > Message: 3 > Date: Wed, 01 Sep 2004 22:18:38 -0400 > From: Jason Parker-Burlingham > Subject: Re: [Buffalo-pm] Where to post perl programming question? > To: buffalo-pm@mail.pm.org > Message-ID: <87sma1l8g1.fsf@freezer.burling> > Content-Type: text/plain; charset=us-ascii > > James Keenan writes: > >> While it *is* possible to teach yourself Perl from Programming Perl >> (a.k.a. the "Camel book"), you should understand: > >> (b) while the Camel book is the standard reference work on the >> language, other books are more focused on enabling you to *learn* >> Perl. > > I would add also Damian Conway's wonderful "Object Oriented Perl", > from Hanning. > > jason > > > ------------------------------ > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm > > End of Buffalo-pm Digest, Vol 15, Issue 2 > ***************************************** > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm > ========================================== Jim Brandt Administrative Computing Services University at Buffalo From eye at buffalo.edu Fri Sep 3 08:05:13 2004 From: eye at buffalo.edu (Kevin Eye) Date: Fri Sep 3 08:05:16 2004 Subject: [Buffalo-pm] Learning Perl In-Reply-To: <830933AF-FDA1-11D8-A819-000A9588183A@buffalo.edu> References: <6FF91AE4F1DC7743A6466E334EB865AE02EB0174@VERITY.roswellpark.org> <830933AF-FDA1-11D8-A819-000A9588183A@buffalo.edu> Message-ID: > For those of you who have any relationship with UB, we now have access > to O'Reilly's Safari service for books (actually, this has been > working all summer, but they just announced it). I think they granted > access by IP, so this might only work on a campus network, but try > these: > > http://proquest.safaribooksonline.com/?uicode=buffalo > http://safari.oreilly.com FYI - off-campus IPs are automatically directed through a proxy that lets you log in with your UB card barcode number and initials. You have to go in through the libraries site, though, I bet: http://ublib.buffalo.edu/libraries/cgi-test/title.cgi?letter=S The books really are great. It even includes a full-catalog, full-text search. - Kevin From bpm at binarymojo.net Fri Sep 3 12:19:40 2004 From: bpm at binarymojo.net (Kevin Christopher) Date: Fri Sep 3 12:19:45 2004 Subject: [Buffalo-pm] September Buffalo Perl Mongers Meeting Message-ID: <55592.64.65.247.81.1094231980.squirrel@my.modwest.com> Fellow Perl Mongers: I hope everyone has had a great summer. After a period of summer hibernation, the ascii buffalo ( @|^|` ) has awakened. Our next meeting is scheduled for Thursday, September 16, 2004 with a tentative location at 242 Bell Hall on the UB North Campus. Our topic is Lightning Talks. Each Lightning Talk will have a time limit of 10 minutes. It's a chance to talk about a favorite Perl module, a cool hack, a feature of the Perl language, or absolutely anything else you'd like to talk about, as long as its related to Perl. If you'd like to know more about what Lightning Talks are, visit http://perl.plover.com/lt/lightning-talks.html You can sign up on this Buffalo Perl Mongers Wiki page: http://buffalo.pm.org/kwiki/index.cgi?September2004Meeting (See http://buffalo.pm.org/kwiki/index.cgi?KwikiFormattingRules and look at the "Simple Tables" section toward the bottom of the page if you have any questions about how about wiki markup when you add your row to the sign-up table.) You can also use this meeting as a dry run for a Lightning Talk you'd like to give at the September 30 Toronto Perl Mongers meeting. See Richard Dice's message at http://mail.pm.org/archives/buffalo-pm/2004-August/000163.html - Kevin Christopher From dmagnuszewski at yahoo.com Thu Sep 9 10:00:55 2004 From: dmagnuszewski at yahoo.com (Daniel Magnuszewski) Date: Thu Sep 9 10:00:57 2004 Subject: [Buffalo-pm] September Buffalo Perl Mongers Meeting In-Reply-To: <55592.64.65.247.81.1094231980.squirrel@my.modwest.com> Message-ID: <20040909150055.67646.qmail@web21126.mail.yahoo.com> All, Perhaps a good talk would be on something you learned or found interesting at YAPC. I know it was a few months ago, and we had planned on doing this in a meeting over the summer, but the meeting ended up not happening. For those of you that have joined the group since YAPC (or haven't been to any meetings) then this will be a good opportunity for you to come out and see what we're all about and what we do. See you next Thursday. -Dan Kevin Christopher wrote: Fellow Perl Mongers: I hope everyone has had a great summer. After a period of summer hibernation, the ascii buffalo ( @|^|` ) has awakened. Our next meeting is scheduled for Thursday, September 16, 2004 with a tentative location at 242 Bell Hall on the UB North Campus. Our topic is Lightning Talks. Each Lightning Talk will have a time limit of 10 minutes. It's a chance to talk about a favorite Perl module, a cool hack, a feature of the Perl language, or absolutely anything else you'd like to talk about, as long as its related to Perl. If you'd like to know more about what Lightning Talks are, visit http://perl.plover.com/lt/lightning-talks.html You can sign up on this Buffalo Perl Mongers Wiki page: http://buffalo.pm.org/kwiki/index.cgi?September2004Meeting (See http://buffalo.pm.org/kwiki/index.cgi?KwikiFormattingRules and look at the "Simple Tables" section toward the bottom of the page if you have any questions about how about wiki markup when you add your row to the sign-up table.) You can also use this meeting as a dry run for a Lightning Talk you'd like to give at the September 30 Toronto Perl Mongers meeting. See Richard Dice's message at http://mail.pm.org/archives/buffalo-pm/2004-August/000163.html - Kevin Christopher _______________________________________________ Buffalo-pm mailing list Buffalo-pm@mail.pm.org http://mail.pm.org/mailman/listinfo/buffalo-pm --------------------------------- Do you Yahoo!? Shop for Back-to-School deals on Yahoo! Shopping. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/buffalo-pm/attachments/20040909/0991f546/attachment.htm From fhew3 at cogeco.ca Thu Sep 9 18:45:22 2004 From: fhew3 at cogeco.ca (Fulko Hew) Date: Thu Sep 9 18:45:25 2004 Subject: [Buffalo-pm] [Fwd: [tpm] lightning talks] Message-ID: <4140EB12.40902@cogeco.ca> -------- Original Message -------- Subject: [tpm] lightning talks Date: Wed, 08 Sep 2004 10:23:54 -0400 A reminder: Sept is the meeting when TPM engages in Lightning Talks :-) This a a popular annual event. This year looks like a great time to participate in the 5 to 15 minute talks that cover any topic that mentions Perl. To date we have offerings as follows: Richard Doing combinatorial work with Perl Indy T.B.D. Pierre mechanize Shawn Shawn's favourite Perl module Nicholas Laboratory Data Collection Fulko Creating Highly Available, Redundant Linux Systems Dan Working with the CPAN Spork module Glenn Catching financial conspirators using Perl Everyone is welcome to present a talk. No previous experience needed. As Chairman I would ask that each presenter supply: - a one line subject title for your talk - a short paragraph that provides an overview of what you intend to talk about. For those not familiar with the Lightning Talk evening, this will give attendees an opportunity to consider what turns the TPM members on. Remember TPM regularly meets on the last Thursday of the month. See our regular TPM meeting announcement. (http://to.pm.org) The Lightning talks will be Thursday, Sept 30. Arrive by 6:30 PM. --- Glenn Chairman for '04 e-mail: gsimpson@mountaincable.net From ecammit at hotmail.com Fri Sep 10 12:04:47 2004 From: ecammit at hotmail.com (Timothy M.Ace) Date: Fri Sep 10 12:04:52 2004 Subject: [Buffalo-pm] Meeting time? Message-ID: <853730F8-034B-11D9-8737-000A95D43DB0@hotmail.com> What time is the meeting at? I failed to notice a time and I can't remember what the time was in the past. -Tim A From bpm at binarymojo.net Fri Sep 10 13:48:40 2004 From: bpm at binarymojo.net (Kevin Christopher) Date: Fri Sep 10 13:48:43 2004 Subject: [Buffalo-pm] Meeting time? In-Reply-To: <853730F8-034B-11D9-8737-000A95D43DB0@hotmail.com> References: <853730F8-034B-11D9-8737-000A95D43DB0@hotmail.com> Message-ID: <49150.64.65.247.81.1094842120.squirrel@my.modwest.com> The time for the meeting is 7:00 p.m. Kevin > What time is the meeting at? I failed to notice a time and I can't > remember what the time was in the past. > > -Tim A > > _______________________________________________ > Buffalo-pm mailing list > Buffalo-pm@mail.pm.org > http://mail.pm.org/mailman/listinfo/buffalo-pm From bpm at binarymojo.net Wed Sep 15 12:02:04 2004 From: bpm at binarymojo.net (Kevin Christopher) Date: Wed Sep 15 12:02:09 2004 Subject: [Buffalo-pm] Reminder: Buffalo-PM Meeting Tomorrow Message-ID: <59448.64.65.247.81.1095267724.squirrel@my.modwest.com> Reminder: The Buffalo Perl Mongers September Meeting is tomorrow night: Thursday, September 16 7:00 p.m. 242 Bell Hall, UB North Campus Topic: Lightning Talks Sign-up for Lightning Talks at http://buffalo.pm.org/kwiki/index.cgi?September2004Meeting Each Lightning Talk will have a time limit of 10 minutes. It's a chance to talk about a favorite Perl module, a cool hack, a feature of the Perl language, or absolutely anything else you'd like to talk about, as long as it's related to Perl. If you'd like to know more about what Lightning Talks are, visit http://perl.plover.com/lt/lightning-talks.html Hope to see you there. Kevin Christopher From ecammit at hotmail.com Thu Sep 16 23:04:04 2004 From: ecammit at hotmail.com (Timothy M.Ace) Date: Thu Sep 16 23:04:21 2004 Subject: [Buffalo-pm] Lightning Talk Notes In-Reply-To: <200409161700.i8GH0BiA000703@www.pm.org> References: <200409161700.i8GH0BiA000703@www.pm.org> Message-ID: <9DAF2D7C-085E-11D9-BB2E-000A95D43DB0@hotmail.com> I added a link to my example code in the kwiki for the talk. The kwiki link again is: http://buffalo.pm.org/kwiki/index.cgi?September2004Meeting -Tim From fhew3 at cogeco.ca Tue Sep 28 16:25:22 2004 From: fhew3 at cogeco.ca (Fulko Hew) Date: Tue Sep 28 16:25:25 2004 Subject: [Buffalo-pm] TPM lightning talks Message-ID: <4159D6C2.8070308@cogeco.ca> The TPM Lightning Talk session is this Thursday, Sept 30. And the presenters are supplying notification of what is on their mind. Here is the lastest information that I have. Quant Finance with Perl Item #2 .. 'Yield Curve' by Richard Testing web pages with Perl by Pierre Getopt::Declare by Shaun Getopt::Declare (by Damian) is yet another command-line argument parser, one which is specifically designed to be powerful but exceptionally easy to use. /Perl (Expert)? Quiz of the Week/ by John A talk on the two mailing lists, /Perl (Expert)? Quiz of the Week/ run by Mark Jason Dominus The talk would describe the two lists, how to join, and show some example quizes from the past 6 months, with a summary of the sort of discussion that arose. Creating Highly Available, Redundant Linux Systems by Fulko Of course the "... using Perl" is a given Automating best testing practices in Class::DBI development by Dan. Dan will be using a CPAN module Spork to prepare his slides so you may get a side topic covering Spork. 21st Century Perl by Micheal Synopsis: Every time a new version of Perl comes out, I salivate over the shiny new syntax features, but I know that because of the demands of backwards compatibility I won't be able to use the features for a long time. But Now I'm making a clean break and refusing to support Perl versions from the last Millenium. Now I get to use with confidence such advanced features as: - autovivifying filehandles - 3 argument open - lexical warnings - the 'our' pragma - can() and isa() - inline foreach Taking a Dump How to perform stack tracing by Fulko Catching financial conspirators using Perl This involves Perl for recreation. The topic will focus on a puzzle published in Dr Dobb's Journal and the use of Perl to aid in solving the puzzle. Listeners are ALWAYS welcome. -- Glenn -- Chairman for the Lightning Talks meeting e-mail: gsimpson@mountaincable.net