From 19d48b33649ec3a854acdfe14aedf0a88e994278 Mon Sep 17 00:00:00 2001 From: per1234 Date: Sun, 3 Feb 2019 03:04:56 -0800 Subject: [PATCH] Add basic example for pow() Previously, the reference page only provided a link to an overly complex example sketch. --- Language/Functions/Math/pow.adoc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Language/Functions/Math/pow.adoc b/Language/Functions/Math/pow.adoc index bf22a9ecf..947d05534 100644 --- a/Language/Functions/Math/pow.adoc +++ b/Language/Functions/Math/pow.adoc @@ -47,7 +47,13 @@ The result of the exponentiation. (`double`) [float] === Example Code // Describe what the example code is all about and add relevant code ►►►►► THIS SECTION IS MANDATORY ◄◄◄◄◄ -See the (http://arduino.cc/playground/Main/Fscale[fscale]) function in the code library. +Calculate the value of x raised to the power of y: +[source,arduino] +---- +z = pow(x, y); +---- +See the (http://arduino.cc/playground/Main/Fscale[fscale]) sketch for a more complex example of the use of `map()`. +[%hardbreaks] -- // HOW TO USE SECTION ENDS