[Haskell-cafe] Re: question

Joe Fredette jfredett at gmail.com
Wed Nov 4 23:14:07 EST 2009

Well, what have you got so far? This sounds like a pretty homeworky  
question, so I don't want to give it away. But try to think about the  
types involved. ASTs in Haskell are just Datatypes, cost minimization  
is a transformation on that type. Try to think about how to combine  
the cost vector and an AST type, and then how to use that combined  
information to "tear down" the structure into the new (minimized)  



On Nov 4, 2009, at 10:42 PM, Mohamed Ayed wrote:

> Can you please help ?
> On Wed, Nov 4, 2009 at 6:10 PM, Mohamed Ayed <mhady7 at gmail.com> wrote:
> Hi,
> I want to write a program that will take an AST and a cost vector   
> that represents a cost for each operation and produce a simplified  
> version of the tree based on cost reduction.
> Can any one give me some ideas ?
> Thanks
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe

More information about the Haskell-Cafe mailing list