update
This commit is contained in:
18
coconut composition de fonction.md
Normal file
18
coconut composition de fonction.md
Normal file
@@ -0,0 +1,18 @@
|
||||
---
|
||||
aliases:
|
||||
- coconut composition simple
|
||||
- coconut opérateur ..
|
||||
- coconut ..
|
||||
---
|
||||
up:: [[coconut composer des fonctions]]
|
||||
#informatique
|
||||
|
||||
la fonction `square_plus_1` correspond à `x -> 1 + x**2`
|
||||
|
||||
```python
|
||||
square = x -> x**2
|
||||
plus_1 = x -> x+1
|
||||
square_plus_1 = plus_1 .. square
|
||||
```
|
||||
La composition est faîte avec `..` et suit l'ordre mathématique de composition : $(f \circ g)(x) = f(g(x))$
|
||||
|
Reference in New Issue
Block a user