SCHOOL OF CODE BUILDERS
Learn To CODE. Become A DEVELOPER.
Pages
HOME
DATA STRUCTURES
STRINGS
ARRAYS
MATRIX
BINARY TREES
LINKED LIST
STACK
QUEUE
SORTING
SEARCHING
C
PYTHON
PSEUDOCODE
CONTEST PROBLEMS
ALGORITHMS
PATTERNS
PHP
C PUZZLES
C INTERVIEW QUESTIONS
JAVA
C++
HASHING
RECURSION
BASIC C PROGRAMS
TCS-CODEVITA
FACEBOOK
CONTACT US
C program to find square root of a number using library function
C program to find square root of a number using library function
Output:
Enter a number to find its square root:
5
The square root of 5 is 2.236068
Implementation:
#include
#include
int main(void) { int n; printf("Enter a number to find its square root:\n"); scanf("%d",&n); printf("The square root of %d is %f",n,sqrt(n)); return 0; }
PREVIOUS
NEXT
HOME