if ($resnum1=$resnum)
Inside the brackets is an assignment. You almost certainly don't want to do that but instead test equality. ie:
if ($resnum1 == $resnum)
== is for comparing numbers and eq is for comparing strings.
Is there any particular reason you use those massive regexes in preference to a simple split? That might make things a little clearer. Other tips: use strict and warnings, replace print ... exit with die and try to use consistent indenting to make your code more legible (this really does help).
Good luck.
In reply to Re: Perl script that will read two pdb files with different line numbers and will replace the chain letter from the first to the second file
by hippo
in thread Perl script that will read two pdb files with different line numbers and will replace the chain letter from the first to the second file
by Nastazia
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |