exp.
Note that 0⁰ (pow(0, 0)) returns 1. Mathematically this is undefined.
Signature
Panics
Panics if the result of the exponentiation operation overflows the output type.Examples
Trait functions
pow
Returnsself to the power exp.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
exp.
Note that 0⁰ (pow(0, 0)) returns 1. Mathematically this is undefined.
pub trait Pow
use core::num::traits::Pow;
assert!(2_i8.pow(4_usize) == 16_i8);
assert!(6_u8.pow(3_usize) == 216_u8);
assert!(0_u8.pow(0_usize) == 1_u8);
self to the power exp.
fn pow(self: Base, exp: Exp) -> PowOutput
type Output;
Was this page helpful?