// Solving by Robinkin from Devonit
INCLUDE #include "mtl / mtl.h" #include "mtl / utils.h" #include "mtl / tinalg_vec.h"
/ * Sample Output;
X: [1, 5, 3, 1,] The L-2 NORM OF X IS 6 * /
Using namespace MTL;
TYPEDEF EXTERNAL_VEC VEC;
INTMAIN () {Double Data [] = {1, 5, 3, 1}; VEC X (Data, 4);
Double s = two_norm (x);
Std :: cout << "x:"; Print_Vector (x);
Std :: cout << "The L-2 Norm of X IS" << S << std :: endl;}