in reply to How to vector
I have a feeling your problem may be in this code:
$aa->[0] = my $one; $aa->[1] = my $two; $aa->[2] = my $three;
You need to define these variables before assigning them, or you'll get the types of errors you're seeing. Are you sure it shouldn't be written like this instead?:
sub vector { my ($aa) = @_; my $one = $aa->[0]; my $two = $aa->[1]; my $three = $aa->[2]; my $vector = V($one, $two, $three); }
-stevieb
ps. I don't have any experience with that module, so I'm just guessing.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: How to vector
by jcklasseter (Sexton) on Jun 19, 2015 at 20:31 UTC | |
by AnomalousMonk (Archbishop) on Jun 19, 2015 at 21:28 UTC |