Re: Time conversion...
Al was right, not tight enough:
function secs_to_mins(integer sex)
return sprintf("%d:%02d", {floor(sex/60),remainder(sex,60)})
end function
jiri
----- Original Message -----
From: "Jim Duffy" <futures8 at earthlink.net>
To: "EUforum" <EUforum at topica.com>
Sent: Sunday, February 25, 2001 9:35 AM
Subject: Re: Time conversion...
> Hi, Vince.
>
> I don't think you're missing a thing. Nice, tight function.
>
> regards,
>
> Jim
>
> Vincegg at AOL.COM wrote:
> >
> > Hello,
> >
> > The code looks very convoluted. Couldn't you just use something
like this or
> > am I missing something?
> >
> > function secs_to_mins(integer secs)
> > integer minutes
> > minutes=floor(secs/60)
> > return sprintf("%d:%02d",{minutes,floor(secs-minutes*60)})
> > end function
> >
> > Would that suffice?
> >
> > Vince
> >
>
>
|
Not Categorized, Please Help
|
|