Upcoming SlideShare
×

# ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน

1,546

Published on

Published in: Technology, Education
0 Likes
Statistics
Notes
• Full Name
Comment goes here.

Are you sure you want to Yes No
Your message goes here
• Be the first to comment

• Be the first to like this

Views
Total Views
1,546
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
18
0
Likes
0
Embeds 0
No embeds

No notes for slide

### Transcript of "ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน"

1. 1. CCC
2. 2. C1 standard functions)1 mathematic functions)1 2–5 -8
3. 3. Character functions)8 String functions)8 - 10
4. 4. C C C Header file C h standard functions) Cheader file C h header file #include<header file.h>
5. 5. C compiler” ” library functions) mathematic functions) #include <math.h> type) double doubleacos(x) asin(x) atan(x)sin(x) cos(x) tan(x)sqrt(x) exp(x) pow(x,y)
6. 6. log(x) log10(x) ceil(x)floor(x) fabs(x) acos(x) arc cosine x x radian) acos(x); 2) asin(x) arc sinex x asin(x);
7. 7. 3) atan(x) arc tanx x atan(x); sin(x) sine x x sin(x); 5) cos(x) cosine x x
8. 8. 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)
9. 9. * math1.c */#include<stdio.h>/*#include<math.h>/*#include<conio.h>/*void main(void)/*{ double r, pi = 3.141592654;/* r = pi/180;/*
10. 10. 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 ..."); /*
11. 11. getch();/*}
12. 12. printf("%fn",asin(r)); arc sin r rprintf("%fn",acos(r)); arc cosine r r
13. 13. printf("%fn",atan(r)); arc tan r rprintf("%fn",sin(r)); sine r rprintf("%fn",cos(r)); cosine r rprintf("%fn",tan(r)); tan r r
14. 14. enter sqrt(x) square root) x x sqrt(x); 8) exp(x) ex x e e exp(x);
15. 15. 9) pow(x,y) xyxy pow(x, y); character functions) single char( byte)#include<ctype.h> isalnum(ch),
16. 16. 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( ) textmode gotoxy(x,y)cursor)
17. 17. sizeof(x) xByte user defined functions) C ” ” ” ” user define functions : UDF) C