3v4l.org

run code in 300+ PHP versions simultaneously
<?php atest(); function atest(){ $test = array( "StartDate" => "08/01/2013", "StartTime" =>"08:00:00", "DepartmentID" => "75275", "# Contacts Offered" => "3", "# Contacts Handled" => "4", "Average Talk Time" => "491.250000", "Average Delay" => "5.666667", "Percent SLA" => "1.333333"); $formatted = sprintf("%s %s TCSDATA %d %d %d %01.2f 0 %01.2f %01.2f 0\r\n", $test["StartDate"], $test["StartTime"], $test['DepartmentID'], $test['# Contacts Offered'], $test['# Contacts Handled'], $test['Average Talk Time'], $test['Average Delay'], $test['Percent SLA'] ); echo('<pre>'); echo( var_dump($test) ); echo('</pre>'); echo $formatted; } ?>

preferences:
52.93 ms | 402 KiB | 5 Q