Más contenido relacionado
La actualidad más candente (20)
Similar a ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน (20)
Más de Noppanon YourJust'one (13)
ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
- 3. C
1
standard functions)
1
mathematic functions)
1
2–5
-8
- 5. C
C
C
Header file C h
standard functions)
C
header file C h
header file
#include<header file.h>
- 6. C compiler
” ” library functions)
mathematic functions)
#include <math.
h>
type) double
double
acos(x) asin(x) atan(x)
sin(x) cos(x) tan(x)
sqrt(x) exp(x) pow(x,y)
- 7. log(x) log10(x) ceil(x)
floor(x) fabs(x)
acos(x)
arc cosine
x x
radian)
acos(x);
2) asin(x)
arc sine
x x
asin(x);
- 8. 3) atan(x)
arc tan
x x
atan(x);
sin(x)
sine x
x
sin(x);
5) cos(x)
cosine x
x
- 9. cos(x);
6) tan(x)
tan x x
tan(x);
acos(x), asin(x),
atan(x), sin(x),
cos(x) tan(x)
acos(x), asin(x), atan(x), sin(x),
cos(x) tan(x)
- 10. * math1.c */
#include<stdio.h>
/*
#include<math.h>
/*
#include<conio.h>
/*
void main(void)
/*
{
double r, pi = 3.141592654;
/*
r = pi/180;
/*
- 11. clrscr();
/*
printf("%fn",asin(r));
/*
printf("%fn",acos(r));
/*
printf("%fn",atan(r));
/*
printf("%fn",sin(r));
/*
printf("%fn",cos(r));
/*
printf("%fn",tan(r));
/*
printf("nPress any key back to program ..."); /*
- 15. enter
sqrt(x)
square root)
x x
sqrt(x);
8) exp(x)
ex x
e e
exp(x);
- 16. 9) pow(x,y)
xy
x
y
pow(x, y);
character functions)
single char
( byte)
#include<ctype.h>
isalnum(ch),
- 17. isalpha(ch), isdigit(ch), islower(ch), isupper(ch),
tolower(ch), toupper(ch),
isspace(ch), isxdigit(ch)
1.3 string functions)
string)
#include<string.h>
strlen(s), strcmp(s1,s2)
, strcpy(s), strcat(s1,s2)
1.4
clrscr( )
text
mode
gotoxy(x,y)
cursor)
- 18. sizeof(x)
x
Byte
user defined functions)
C
” ”
” ”
user define functions : UDF)
C