The error message is quite explicit, you are passing an integer
argument to a function which expects a real
argument. You could change this line
resultat = moyen(100,50)
to
resultat = moyen(100.0,50.0)
In fact, as you can see, you are making the same mistake twice in one line, the compiler is just identifying the first occurrence.