About 16,900,000 results
Open links in new tab
  1. C Program to Calculate the Power of a Number

    Write a function to calculate the power of a number. For example, with inputs base = 2 and exponent = 3, the return value should be 8. Did you find this article helpful? In this example, …

  2. math - To the power of in C? - Stack Overflow

    You need pow() function from math.h header. Here x is base and y is exponent. Result is x^y. And make sure you include math.h to avoid warning (" incompatible implicit declaration of built in …

  3. Power Function in C | GeeksforGeeks

    Apr 30, 2025 · In C language, the pow() function is defined in the <math.h> header file and is used to calculate the exponent value of x raised to the power of y, i.e., x y. Basically, in C, the …

  4. C Program To Implement Power Function - Edureka

    Mar 14, 2023 · In this article we will understand how to write a program by using Power Function In C to calculate power of a number. Following pointers will be covered in this article,

  5. C Program to Find Power of a Number Using Function

    We will write a C program to find the power of a number using a function. First, we will use the pre-defined function pow(), and later we will develop a user-defined function.

  6. Power of a Number in C with Example - Sanfoundry

    Here is a C program to find the power of a number using while loop, for loop, recursion and pow function, along with an explanation and examples.

  7. C Language: pow function (Power) - TechOnTheNet

    C Language: pow function (Power) In the C Programming Language, the pow function returns x raised to the power of y. Syntax. The syntax for the pow function in the C Language is: double …

  8. C pow() - C Standard Library - Programiz

    The pow() function takes two arguments (base value and power value) and, returns the power raised to the base number. For example, [Mathematics] x y = pow(x, y) [In programming]

  9. Calculate Power of a Given Number in C - Online Tutorials Library

    Learn how to calculate the power of a given number in C programming with this comprehensive guide. Step-by-step examples and explanations included.

  10. How do you do exponentiation in C? - Stack Overflow

    Dec 24, 2024 · Generally speaking, pow(2, x) == (1 << x) So, pow(2, 4) == 16 and (1 << 4) == 16) If you want a fast floating-point integral power of 2, you can use ldexp -- ldexp(1.0, 100) will …

  11. Some results have been removed
Refresh