Einzelnen Beitrag anzeigen

pastra

Registriert seit: 23. Jun 2006
21 Beiträge
 
#1

java to delphi

  Alt 26. Feb 2009, 02:50
I am trying to translate this java code to delphi:

Delphi-Quellcode:
String FlashG(int fromINT, int toINT)
    {
        StringBuffer stringbuffer = new StringBuffer();
        int PPP;
        for(PPP = toINT; PPP < fromINT; PPP *= toINT);
        do
        {
            int OOP = fromINT / PPP;
            char COMP = (char)(LEVEL + OOP);
            stringbuffer.append(COMP);
            fromINT -= PPP * OOP;
            PPP /= toINT;
        }
 while(PPP > 0);
        return stringbuffer.toString();
    }


LEVEL = 'K';

It goes fine to the point of the for loop. Can't figure it out.. PPP is changed in the for loop?

If anyone can translate it, it will be greatly appreciated.

Cheers


Regards PasTra
  Mit Zitat antworten Zitat