MoshiachNow
IS-IT--Management
HI,
How do I convert,say, 3911 seconds to format 01:05:11 ?
Thanks
Long live king Moshiach !
How do I convert,say, 3911 seconds to format 01:05:11 ?
Thanks
Long live king Moshiach !
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
my $fTotalTime = 3911; # amount of seconds
my $iMinutes = $fTotalTime/60;
# round it
$iMinutes =~ s/\..+$//;
# seconds
my $iSeconds = $fTotalTime % 60;
print "$fTotalTime seconds is $iMinutes minutes, and $iSeconds seconds\n";
use strict;
use POSIX;
my $interval = 123412;
my $Hours = floor($interval/3600); # calculate precise, and then floor it
my $Minutes = floor(($interval - $Hours * 3600) / 60);
my $Seconds = $interval % 60;
print "$Hours:$Minutes:$Seconds";
use strict;
my $interval = 123412;
my $Hours = int($interval/3600); # calculate precise, and then floor it
my $Minutes = int(($interval - $Hours * 3600) / 60);
my $Seconds = $interval % 60;
print "$Hours:$Minutes:$Seconds";
use strict;
my $interval = 123412;
my $hours = int($interval/3600); # calculate precise, and then floor it
my $minutes = int(($interval - $hours * 3600) / 60);
my $seconds = $interval % 60;
my $time = sprintf"("%d:%02d:%02d", $hours, $minutes, $seconds);
print "$time";