diff --git a/module2/exo1/toy_document_fr.Rmd b/module2/exo1/toy_document_fr.Rmd index ffb0dce78e010a8fb91f8b4bb46073d9719b0d08..49d651db6941312f35d351751c9b1bbc20cc4bc1 100644 --- a/module2/exo1/toy_document_fr.Rmd +++ b/module2/exo1/toy_document_fr.Rmd @@ -19,3 +19,12 @@ print(p) #Lien aiguille de buffon [Aiguille de Buffon](https://fr.wikipedia.org/wiki/Aiguille_de_Buffon) + +```{r} +set.seed(42) +N = 100000 +x = runif(N) +theta = pi/2*runif(N) +R=2/(mean(x+sin(theta)>1)) +plot=R +```