AFL a powerful and flexible language  -  YES ! 

A math teacher friend of mine gave me the following problem:

   ELF
 + ELF
________

  FOOL

Each letter is an integer variable over the range 0 - 9.
Find the values of E, L, F, O.

After contemplating solving 4 equations in 4 unknowns, I decided to
solve it by brute force with AFL.  Coded as follows:

//     elf
//   + elf
//_______
//    fool

for (eee = 0; eee < 10; eee++)
        {
        for ( lll = 0; lll < 10; lll = lll + 2 )
        {
        for( fff = 0; fff < 10; fff++ )
        {
        elf = 100 * eee + 10 * lll + fff ;
        for (ooo = 0; ooo < 10; ooo++ )
        {
        fool = 1000*fff + 100*ooo + 10*ooo + lll;
        if(2*elf[fff] == fool[ooo])
        printf("eee= " + eee + " lll= " + lll + " fff= " + fff + " ooo= " +
ooo + "\n" ) ;
        else
        xxx=0 ;
        }
        }
        }
        }

Excuse the wrapping.  

AFL is GREAT !

ReefBreak

--- In [email protected], "brian_z321" <[EMAIL PROTECTED]> wrote:
>
> --- In [email protected], "jim_trades_stocks" <jnk1997@> 
> wrote:
> >
> > Forget about trading, making money...Baaah!, no time for that!
> >  
> > Your mission is to keep up with the advanced functions, 
> capabilities 
> > and coding of Amibroker for a lifetime adventure of backtesting and 
> > viewing theoretical equity curves.  
> > 
> > I Guess the new evolutionary "AFL Wizard" didn't make it within 2 
> > months as was promised.
> 
> Jim,
> 
> No one knows how to push peoples buttons more than a sales executive.
> 
> So you want your Formula Wizard and you want it now and you mounted a 
> public campagn to bustle Tomasz into doing it?
> 
> I am a goer myself so I have a sneaking regard for others who have 
> balls ;-)
> 
> Perhaps you, and others, should consider the affect that this public 
> and constant tearing away at Tomasz's persona has on him.
> 
> He is a brilliant person but he is also human, just like us.
> 
> On top of that you divert Tomasz's attention away from productive 
> tasks and the same applies to group members who have to come in and 
> post to provide some balance.
> 
> Also, I think you will find  there are better ways to get what you 
> want without the need for public blustering.
> 
> I am an aggressive person but I have learnt that controlled 
> aggression, proactively directed, is the way to use that energy 
> constructively; sport is the arena where this is most apparent to any 
> observer.
> 
> As I said in another post, I have found Tomasz very approachable, yes 
> even susceptible, to a well presented private petition.
> 
> 
> FTR
> 
> I have been a persistent and strong campaigner on user easy features 
> since I joined the Ami forum but a Formula Wizard does not get my 
> vote.
> I have used them in other programs and they just don't do anything 
> for me.
> However if Tomasz wants to do it there will be no complaints from me.
> 
> The reason?
> 
> I trust Tomasz's ability to steer the ship, and, aside from offering 
> no strings attached suggestions here and there I leave him to get on 
> with his job and I get on with mine.
> 
> 55 years old has nothing to do with it.
> Neither does *I am not trained in programming or computers*
> *I have a full time job and a family to care for* has a lot to do 
> with it.
> 
> I empathise with the fact that you are a road warrior; a tough career 
> choice.
> 
> All the best for your career and your trading,
> 
> Brian.
>


Reply via email to