pRaNaV:
You'll likely have to clarify your question. As I read it, you're probably wanting to compute the logarithm of a sum using a base other than e. But since the documentation for the log function (which you can read via perldoc -f log) covers this, I'm hard pressed to imagine that's what you actually want. But if you did want that, then:
my ($x, $y, $base) = (23.5, 54.3, 2.0);
my $result = log($x + $y) / log($base);
print "result: $result\n";
...roboticus
When your only tool is a hammer, all problems look like your thumb. |