Hmm, instead of dividing the values - i would multiply them.
Actually: 1 BTC = 633 USD and 633 USD =~ 6000 UAH. So i would calculate: $uah = $spot_last * $exrate;
Example
<?php
header('Cache-Control: no-cache, no-store, must-revalidate'); // HTTP 1.1.
header('Pragma: no-cache'); // HTTP 1.0.
header('Expires: 0'); // Proxies.
// get BTC
$data = file_get_contents("https://btc-e.com/api/2/btc_usd/ticker");
$data = json_decode($data, true);
$spot_last = $data['ticker']['last'];
echo '1 BTC is worth ' . $spot_last . ' USD. <br>';
// get CURRENCIES
$xml = simplexml_load_file("https://api.privatbank.ua/p24api/pubinfo?exchange&coursid=5");
$m = $xml->xpath('//exchangerate[@ccy="USD"]');
$exrate = (string)$m[0]['buy'];
echo '1 USD is worth '. $exrate .' UAH. <br>';
$uah = $spot_last * $exrate;
echo 'Result: 1 BTC ~ ' . $uah . ' UAH. <br>';
For usage as ticker, delete all echos statements, they are just for demonstration and insert just echo $uah;
Output
1 BTC is worth 624.928 USD.
1 USD is worth 9.60000 UAH.
1 BTC ~ 5999.3088 UAH.
Comparison Calc
By the way: it's pretty awesome that Privatbank provides such an API.