FP (programming language): Difference between revisions

Content deleted Content added
m --> es:
Danakil (talk | contribs)
Line 17:
'''constant''' '''x̄''' where '''x̄''':'''y''' = '''x'''
 
for all values '''y''' (except the '''undefined''' value, '''⊥''', which all functions map into itself, due to their being [[strict function|strict]]). Next there are the threeremaining principal functionals of FP:
 
'''composition''' '''f'''&#x°'''g''' where '''f'''&#x°'''g''':'''x''' = '''f''':('''g''':'''x''')
 
'''construction''' ['''f'''<sub>1</sub>,...'''f'''<sub>n</sub>] where ['''f'''<sub>1</sub>,...'''f'''<sub>n</sub>]:'''x''' = &lang; '''f'''<sub>1</sub>:'''x''',...,'''f'''<sub>n</sub>:'''x''' &rang;
 
'''condition''' ('''h''' &rArr; '''f''';'''g''') where ('''h''' &rArr; '''f''';'''g'''):'''x''' = '''f''':'''x''' if '''h''':'''x''' = '''T'''
and ('''h''' &rArr; '''f''';'''g'''):'''x''' = '''g''':'''x''' if '''h''':'''x''' = '''F'''
and ('''h''' &rArr; '''f''';'''g'''):'''x''' = '''&#8869;''' otherwise
 
'''apply-to-all''' ''&alpha;'''''f''' where ''&alpha;'''''f''':&lang;'''x'''<sub>1</sub>,...,'''x'''<sub>n</sub>&rang; = &lang;'''f''':'''x'''<sub>1</sub>,...,'''f''':'''x'''<sub>n</sub>&rang;
 
'''insert-right''' /'''f''' where /'''f''':&lang;'''x'''&rang; = '''x'''
and /'''f''':&lang;'''x'''<sub>1</sub>,'''x'''<sub>2</sub>,...,'''x'''<sub>n</sub>&rang; = '''f''':&lang;'''x'''<sub>1</sub>,'''f''':&lang;'''x'''<sub>2</sub>,...,'''x'''<sub>n</sub>&rang;&rang;
 
[[es:FP (lenguaje de programación)]]