+1 sagar pareek...
i used the following approach:
let the num be xy
so...
(10y + x) - (10x + y) is the distance travelled in 1 hr...
now, the the next milestone must be a three digit number, which can be of
following compostion: 1xy or xzy or yzx whr 0<=z<9 coz aif z=9, distance
travlled in tht hr wud be more thn 100, which can nt be the case( in
contradiction with the distance in 1st hr)...
now if its 1xy,
9(y-x) = 100 + 9 (x-y) which can nt give integral soln..so num must be
xzy...thn
9(y-x) = 99x + 10z - 9y...
now fr integral solution: z must be a multiple of 9, can be 0 or 9...
hence it has to be 0.
so 9(y-x)=9(11x-y)
2y=12x
y=6x
posbl soln:
x=0,y=0...rejected
x=1, y=6...
accepted

On Wed, Aug 17, 2011 at 11:22 PM, Rohit Srivastava
<[email protected]>wrote:

> logic plz?
>
> On Wed, Aug 17, 2011 at 10:35 PM, sagar pareek <[email protected]>wrote:
>
>> 16, 61, 106  average speed is 45 miles/hour
>>
>>
>> On Wed, Aug 17, 2011 at 10:28 PM, priya ramesh <
>> [email protected]> wrote:
>>
>>> A car is traveling at a uniform speed.The driver sees a milestone showing
>>> a 2-digit number. After traveling for an hour the driver sees another
>>> milestone with the same digits in reverse order.After another hour the
>>> driver sees another milestone containing the same two digits. What is the
>>> average speed of the driver?
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to [email protected].
>>> To unsubscribe from this group, send email to
>>> [email protected].
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>
>>
>> --
>> **Regards
>> SAGAR PAREEK
>> COMPUTER SCIENCE AND ENGINEERING
>> NIT ALLAHABAD
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to [email protected].
>> To unsubscribe from this group, send email to
>> [email protected].
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to