How to resolve the algorithm Averages/Root mean square step by step in the 11l programming language

Published on 12 May 2024 09:40 PM

How to resolve the algorithm Averages/Root mean square step by step in the 11l programming language

Table of Contents

Problem Statement

Compute the   Root mean square   of the numbers 1..10.

The   root mean square   is also known by its initials RMS (or rms), and as the quadratic mean. The RMS is calculated as the mean of the squares of the numbers, square-rooted:

Let's start with the solution:

Step by Step solution about How to resolve the algorithm Averages/Root mean square step by step in the 11l programming language

Source code in the 11l programming language

F qmean(num)
   R sqrt(sum(num.map(n -> n * n)) / Float(num.len))

print(qmean(1..10))

  

You may also check:How to resolve the algorithm Flow-control structures step by step in the Python programming language
You may also check:How to resolve the algorithm Rot-13 step by step in the Tcl programming language
You may also check:How to resolve the algorithm French Republican calendar step by step in the Sidef programming language
You may also check:How to resolve the algorithm Break OO privacy step by step in the ABAP programming language
You may also check:How to resolve the algorithm Floyd-Warshall algorithm step by step in the Rust programming language