www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - For: [your code hear]

reply Manfred Nowak <svv1999 hotmail.com> writes:
Goal: show some skill of D for implementing mathematics. 

A definition:

Let T1, T2, T3 be sets. A problem P of type ( T1, T2, T3) is 
interpretable as a function from the domain
   cartesian product of T1 and powerset of T2
to the codomain
   T3.

Objective: Present code, that is usefull for all P, i.e. for all 
variations of ( T1, T2, T3) and all algoritm to compute the map from 
the domain to the codomain.

-manfred
Feb 07 2012
parent Timon Gehr <timon.gehr gmx.ch> writes:
On 02/07/2012 08:16 PM, Manfred Nowak wrote:
 Goal: show some skill of D for implementing mathematics.

 A definition:

 Let T1, T2, T3 be sets. A problem P of type ( T1, T2, T3) is
 interpretable as a function from the domain
     cartesian product of T1 and powerset of T2
 to the codomain
     T3.

 Objective: Present code, that is usefull for all P, i.e. for all
 variations of ( T1, T2, T3) and all algoritm to compute the map from
 the domain to the codomain.

 -manfred

T3 foo(T1,Set!T2);
Feb 07 2012