Abstract : Most of statistical procedures consist on estimating parameters by minimizing (or maximizing) some criterion. A minimizing parameter is also called in the literature M-estimator, . Depending on the statistical problem and the available information, the criterion may be more or less complicated: non convex, no gradient, non smooth etc... Thus, it can be difficult in practice to compute an M-estimator. We propose a new algorithm to compute the parameters, mixing stochastic algorithms and smoothness technics. We will call it S2Dyn for Stochastic & Smooth Dynamic algorithm.