V wrote:
>
> Following is what I can think of...but it doesn't seem to be
> working ;- ( Any pointers...Thanks!
>
> inline u64 multiplyPower_iter (u64 V, u8 i, u64 c)
> {
> u64 result=1;
> int j;
>
> if ((i == 0))
> return V;
> else
> {
> {
> while (i--)
> {
> result *= 2;
> }
>
> result *= mul (V,c);
> }
> return result;
> }
> }
I have no idea what this is about, since you didn't bother to quote
anything. However, consider how much more understandable the above
is when written (generating same code) as:
inline u64 multiplyPower_iter(u64 V, u8 i, u64 c)
{
u64 result = 1;
int j;
if (i) {
while (i--) result *= 2;
return result * mul(V, c);
}
else return V;
}
--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>
Try the download section.
** Posted from http://www.teranews.com
**


|