Re: [Tutor] Convert an IP address from binary to decimal

2011-01-18 Thread Tom Lin
于 2011-1-18 21:08, Christian Witts 写道: > On 18/01/2011 14:45, Tom Lin wrote: >> Hi guys, >> >> Please help me with this: >> Convert an IP address from binary string to decimal format.There are >> some preconditions: >> 1.IP address is in the form of '00

[Tutor] Convert an IP address from binary to decimal

2011-01-18 Thread Tom Lin
Hi guys, Please help me with this: Convert an IP address from binary string to decimal format.There are some preconditions: 1.IP address is in the form of '10010001100'.32 bits with no dot. 2.int(string, base) is not allowed, You have to implement the conversion . 3.Performance should be c