how do u explain this
void Rectangle::setLength( double l )
{
length = l > 0 && l < 20.0 ? l : 1.0;
}
how do u explain this
void Rectangle::setLength( double l )
{
length = l > 0 && l < 20.0 ? l : 1.0;
}
C++ Is cool
If l is greater than 0 and less than 20, return l, otherwise return 1 :-)
*Cela*
i THINK its u could say:
is lenght between 0 and 20
if not l is equal to 1
?? am i right ??
>otherwise return 1 :-)
Return what?
let length equal l if l is greater than zero and less than twenty but if l is less than or equal to zero or greater than or equal to twenty let length equal one.
Last edited by JoeSixpack; 02-10-2003 at 05:49 PM.
Joe
thanks a lot i understand now what i am doing
C++ Is cool