SlideShare a Scribd company logo
1 of 22
standard functions)

                               C
header file        C                       h

header file
   include<header file.h>

                              C compiler


       library functions)
pow(x,y)
      xy             x       y
 double           pow(x,y)
header file       math.h
   include<math.h>
                 main
    pow(x,y)
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)
log(x)             log (x)        ceil(x)
floor(x)           fabs(x)
acos(x)
arc cosine         x      x
     radian)            acos(x);
          asin(x)
arc sine         x      x
     asin(x);
          atan(x)
arc tan         x      x
     atan(x);
           sin(x)
sine        x        x
      sin(x);
           cos(x)
 cosine       x           x
              cos(x);
         tan(x)
 tan       x        x
       tan(x);
acos(x),
asin(x), atan(x), sin(x), cos(x)                   tan(x)

                               /*        math1.c            */
       #include<stdio.h>                                            /*
        include<math.h>                                             /*
        include<conio.h>                                            /*
      void main(void)                                                /*

             double r, pi = 3.141592654;                          /*
            r = pi/180;                                            /*
            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 ..."); /*
           getch();                                               /*
printf("%fn",asin(r));
arc sin              r       r

     printf("%fn",acos(r));
arc cosine             r          r

        printf("%fn",atan(r));
arc tan              r      r

        printf("%fn",sin(r));
sine               r       r
printf("%fn",cos(r));
  cosine              r       r

         printf("%fn",tan(r));
  tan             r       r



enter
sqrt(x)
                         square root)
         x           x

sqrt(x);
    exp(x)
                    ex       x
                         e       e

exp(x);
    pow(x,y)
               xy
pow(x, y);
sqrt(x), exp(x)             pow(x, y)
                         /*        math2.c */
#include<stdio.h>                                       /*

 include<math.h>                                        /*

 include<conio.h>                                       /*

                                  void
 main(void)                                        /*



     double x = 2.5, y = 7.0, z = 21.5;            /*

     clrscr( );                                    /*

    printf("%.4fn",pow(x,y));                      /*

    printf("%.4fn",sqrt(z));                       /*

    printf("%.4fn",exp(y));                        /*
printf("%.4fn",pow(x,y));
 xy        x
                        y

  printf("%.4fn",sqrt(z));
               square root)
z         z
   printf("%.4fn",exp(y));
    ey         y
             e         e
log(x)
                             log       n (natural
logarithm)                         x        x

           log(x);
                 log10(x)
                       log
         x          x

          log10(x);
               ceil(x)

     x       x                                 x

          ceil(x);
floor(x)

x     x                               x

    floor(x);
           fabs(x)
                         absolute value)
                x    x

    fabs(x);
clrscr( )

  text mode
     clrscr( );
          gotoxy(x,y)
                        cursor)

   gotoxy(x,y );
        clreol( )

cursor
 cursor
    clreol( );
deline( )

cursor

   deline( );
           insline( )

            cursor
    insline( );
           sizeof(x)
                                    x
     Byte
     sizeof(x);
          system( ) sizeof(type);

 MS-DOS
    system(“dos-command”);
abort( )


     Abnormal program termination”

        abort( );
             abs(x)
                                x        x

         abs(x);

atoi( ) char numstr[20] = “1000”; int d;d =atoi(numstr);
printf (“%d”, d);
atoi( ), atof(
)       atol( )
                              /*        atoifl.c           */
     #include<stdio.h>                                                  /*
      include<stdlib.h>                                                 /*
      include<conio.h>                                                  /*
    void main(void)                                                      /*


          char s1[5] = "123";                                        /*
           char s2[10] = "14.573";                                  /*
           char s3[15] = "1234567891";                              /*
           int as1; float fs2; long ls3;                            /*
         clrscr( );                                                /*
         as1 = 2 * atoi(s1);                                       /*
         fs2 = 2 * atof(s2);                                       /*
          ls3 = atol(s3);                                          /*
         printf("AS1 = %dn",as1);                                  /*
         printf("FS2 = %fn",fs2);                                  /*
         printf("LS3 = %ldn",ls3);                                /*
               printf("nPress any key back to program ..."); /*
         getch();                                                  /*
atoi( )               s1

                                 as1
                 atof( )               s2

                           fs2
                 atol( )               s3
                 long integer
ls3

as1, fs2   as3
15

     18

19

More Related Content

What's hot

2 3. standard io
2 3. standard io2 3. standard io
2 3. standard io
웅식 전
 
Travel management
Travel managementTravel management
Travel management
1Parimal2
 
「Frama-Cによるソースコード検証」 (mzp)
「Frama-Cによるソースコード検証」 (mzp)「Frama-Cによるソースコード検証」 (mzp)
「Frama-Cによるソースコード検証」 (mzp)
Hiroki Mizuno
 
Cursor implementation
Cursor implementationCursor implementation
Cursor implementation
vicky201
 

What's hot (20)

C program to implement linked list using array abstract data type
C program to implement linked list using array abstract data typeC program to implement linked list using array abstract data type
C program to implement linked list using array abstract data type
 
Primer Punto
Primer PuntoPrimer Punto
Primer Punto
 
Tu1
Tu1Tu1
Tu1
 
Let's golang
Let's golangLet's golang
Let's golang
 
Vcs8
Vcs8Vcs8
Vcs8
 
2 3. standard io
2 3. standard io2 3. standard io
2 3. standard io
 
Travel management
Travel managementTravel management
Travel management
 
Are we ready to Go?
Are we ready to Go?Are we ready to Go?
Are we ready to Go?
 
Javascript: The Important Bits
Javascript: The Important BitsJavascript: The Important Bits
Javascript: The Important Bits
 
Circular queue
Circular queueCircular queue
Circular queue
 
Final ds record
Final ds recordFinal ds record
Final ds record
 
「Frama-Cによるソースコード検証」 (mzp)
「Frama-Cによるソースコード検証」 (mzp)「Frama-Cによるソースコード検証」 (mzp)
「Frama-Cによるソースコード検証」 (mzp)
 
Concurrent Application Development using Scala
Concurrent Application Development using ScalaConcurrent Application Development using Scala
Concurrent Application Development using Scala
 
Cursor implementation
Cursor implementationCursor implementation
Cursor implementation
 
Programming ppt files (final)
Programming ppt files (final)Programming ppt files (final)
Programming ppt files (final)
 
我在豆瓣使用Emacs
我在豆瓣使用Emacs我在豆瓣使用Emacs
我在豆瓣使用Emacs
 
CROCHET - Checkpoint Rollback in JVM (ECOOP 2018)
CROCHET - Checkpoint Rollback in JVM (ECOOP 2018)CROCHET - Checkpoint Rollback in JVM (ECOOP 2018)
CROCHET - Checkpoint Rollback in JVM (ECOOP 2018)
 
Burrowing through go! the book
Burrowing through go! the bookBurrowing through go! the book
Burrowing through go! the book
 
StewartPlatform_cpp
StewartPlatform_cppStewartPlatform_cpp
StewartPlatform_cpp
 
Session07 recursion
Session07 recursionSession07 recursion
Session07 recursion
 

Viewers also liked

hva_vitaal_werken_nakijken_zonder_stress_mehra
hva_vitaal_werken_nakijken_zonder_stress_mehrahva_vitaal_werken_nakijken_zonder_stress_mehra
hva_vitaal_werken_nakijken_zonder_stress_mehra
Sumit Mehra
 
Step 1 your invitation to make a conscious choice
Step 1 your invitation to make a conscious choiceStep 1 your invitation to make a conscious choice
Step 1 your invitation to make a conscious choice
kosmodevelopers
 
6-Cm10 noté
6-Cm10 noté6-Cm10 noté
6-Cm10 noté
mathome79
 
сквер дк салют
сквер дк салютсквер дк салют
сквер дк салют
Atner Yegorov
 
Paso 1 una eleccion consciente kt
Paso 1 una eleccion consciente ktPaso 1 una eleccion consciente kt
Paso 1 una eleccion consciente kt
kosmodevelopers
 
000 cge company_overview_eng_20120323
000 cge company_overview_eng_20120323000 cge company_overview_eng_20120323
000 cge company_overview_eng_20120323
tommy62dm
 

Viewers also liked (20)

El liderazgo de los emprendimientos sociales
El liderazgo de los emprendimientos socialesEl liderazgo de los emprendimientos sociales
El liderazgo de los emprendimientos sociales
 
hva_vitaal_werken_nakijken_zonder_stress_mehra
hva_vitaal_werken_nakijken_zonder_stress_mehrahva_vitaal_werken_nakijken_zonder_stress_mehra
hva_vitaal_werken_nakijken_zonder_stress_mehra
 
Tip
TipTip
Tip
 
Nigeria Debt Crisis Over the Years - A tale of Seven Presidents
Nigeria Debt Crisis Over the Years - A tale of Seven PresidentsNigeria Debt Crisis Over the Years - A tale of Seven Presidents
Nigeria Debt Crisis Over the Years - A tale of Seven Presidents
 
Class feedback of my magazine
Class feedback of my magazineClass feedback of my magazine
Class feedback of my magazine
 
Mindmapping
MindmappingMindmapping
Mindmapping
 
LT GAME JAM 2015
LT  GAME JAM 2015LT  GAME JAM 2015
LT GAME JAM 2015
 
Step 1 your invitation to make a conscious choice
Step 1 your invitation to make a conscious choiceStep 1 your invitation to make a conscious choice
Step 1 your invitation to make a conscious choice
 
Invenzioni
InvenzioniInvenzioni
Invenzioni
 
Edienkarte
EdienkarteEdienkarte
Edienkarte
 
6-Cm10 noté
6-Cm10 noté6-Cm10 noté
6-Cm10 noté
 
Responsabilidad medioambiental
Responsabilidad medioambientalResponsabilidad medioambiental
Responsabilidad medioambiental
 
Losgrandesgrupos
LosgrandesgruposLosgrandesgrupos
Losgrandesgrupos
 
сквер дк салют
сквер дк салютсквер дк салют
сквер дк салют
 
Paso 1 una eleccion consciente kt
Paso 1 una eleccion consciente ktPaso 1 una eleccion consciente kt
Paso 1 una eleccion consciente kt
 
Mood board indie
Mood board indieMood board indie
Mood board indie
 
000 cge company_overview_eng_20120323
000 cge company_overview_eng_20120323000 cge company_overview_eng_20120323
000 cge company_overview_eng_20120323
 
трио Easy tone
трио Easy toneтрио Easy tone
трио Easy tone
 
Alejandra
AlejandraAlejandra
Alejandra
 
Drafts proposal
Drafts proposalDrafts proposal
Drafts proposal
 

Similar to โปรแกรมย่อยและฟังชันก์มาตรฐาน

ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐานภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
Noppanon YourJust'one
 
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
Little Tukta Lita
 
ภาษาซี
ภาษาซีภาษาซี
ภาษาซี
kramsri
 
ภาษาซี
ภาษาซีภาษาซี
ภาษาซี
kramsri
 
C basics
C basicsC basics
C basics
MSc CST
 
CL metaprogramming
CL metaprogrammingCL metaprogramming
CL metaprogramming
dudarev
 
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6 1
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6  1ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6  1
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6 1
Little Tukta Lita
 
Cg my own programs
Cg my own programsCg my own programs
Cg my own programs
Amit Kapoor
 

Similar to โปรแกรมย่อยและฟังชันก์มาตรฐาน (20)

ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐานภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
ภาษา C โปรแกรมย่อยและฟังก์ชันมาตรฐาน
 
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
โปรแกรมย่อยและฟังชั่นมาตรฐาน ม.6 1
 
String Manipulation Function and Header File Functions
String Manipulation Function and Header File FunctionsString Manipulation Function and Header File Functions
String Manipulation Function and Header File Functions
 
Cquestions
Cquestions Cquestions
Cquestions
 
C questions
C questionsC questions
C questions
 
ภาษาซี
ภาษาซีภาษาซี
ภาษาซี
 
ภาษาซี
ภาษาซีภาษาซี
ภาษาซี
 
C basics
C basicsC basics
C basics
 
C lab manaual
C lab manaualC lab manaual
C lab manaual
 
Blocks+gcd入門
Blocks+gcd入門Blocks+gcd入門
Blocks+gcd入門
 
C programms
C programmsC programms
C programms
 
7 functions
7  functions7  functions
7 functions
 
Functions in c
Functions in cFunctions in c
Functions in c
 
CL metaprogramming
CL metaprogrammingCL metaprogramming
CL metaprogramming
 
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6 1
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6  1ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6  1
ฟังก์ชั่นย่อยและโปรแกรมมาตรฐาน ม. 6 1
 
BCSL 058 solved assignment
BCSL 058 solved assignmentBCSL 058 solved assignment
BCSL 058 solved assignment
 
Cpds lab
Cpds labCpds lab
Cpds lab
 
Cg my own programs
Cg my own programsCg my own programs
Cg my own programs
 
week-23x
week-23xweek-23x
week-23x
 
Go: It's Not Just For Google
Go: It's Not Just For GoogleGo: It's Not Just For Google
Go: It's Not Just For Google
 

Recently uploaded

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Recently uploaded (20)

AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 

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

  • 1.
  • 2. standard functions) C header file C h header file include<header file.h> C compiler library functions)
  • 3. pow(x,y) xy x y double pow(x,y) header file math.h include<math.h> main pow(x,y)
  • 4. 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) log(x) log (x) ceil(x) floor(x) fabs(x)
  • 5. acos(x) arc cosine x x radian) acos(x); asin(x) arc sine x x asin(x); atan(x) arc tan x x atan(x); sin(x) sine x x sin(x); cos(x) cosine x x cos(x); tan(x) tan x x tan(x);
  • 6. acos(x), asin(x), atan(x), sin(x), cos(x) tan(x) /* math1.c */ #include<stdio.h> /* include<math.h> /* include<conio.h> /* void main(void) /* double r, pi = 3.141592654; /* r = pi/180; /* 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 ..."); /* getch(); /*
  • 7.
  • 8. printf("%fn",asin(r)); arc sin r r printf("%fn",acos(r)); arc cosine r r printf("%fn",atan(r)); arc tan r r printf("%fn",sin(r)); sine r r
  • 9. printf("%fn",cos(r)); cosine r r printf("%fn",tan(r)); tan r r enter
  • 10. sqrt(x) square root) x x sqrt(x); exp(x) ex x e e exp(x); pow(x,y) xy pow(x, y);
  • 11. sqrt(x), exp(x) pow(x, y) /* math2.c */ #include<stdio.h> /* include<math.h> /* include<conio.h> /* void main(void) /* double x = 2.5, y = 7.0, z = 21.5; /* clrscr( ); /* printf("%.4fn",pow(x,y)); /* printf("%.4fn",sqrt(z)); /* printf("%.4fn",exp(y)); /*
  • 12.
  • 13. printf("%.4fn",pow(x,y)); xy x y printf("%.4fn",sqrt(z)); square root) z z printf("%.4fn",exp(y)); ey y e e
  • 14. log(x) log n (natural logarithm) x x log(x); log10(x) log x x log10(x); ceil(x) x x x ceil(x);
  • 15. floor(x) x x x floor(x); fabs(x) absolute value) x x fabs(x);
  • 16. clrscr( ) text mode clrscr( ); gotoxy(x,y) cursor) gotoxy(x,y ); clreol( ) cursor cursor clreol( );
  • 17. deline( ) cursor deline( ); insline( ) cursor insline( ); sizeof(x) x Byte sizeof(x); system( ) sizeof(type); MS-DOS system(“dos-command”);
  • 18. abort( ) Abnormal program termination” abort( ); abs(x) x x abs(x); atoi( ) char numstr[20] = “1000”; int d;d =atoi(numstr); printf (“%d”, d);
  • 19. atoi( ), atof( ) atol( ) /* atoifl.c */ #include<stdio.h> /* include<stdlib.h> /* include<conio.h> /* void main(void) /* char s1[5] = "123"; /* char s2[10] = "14.573"; /* char s3[15] = "1234567891"; /* int as1; float fs2; long ls3; /* clrscr( ); /* as1 = 2 * atoi(s1); /* fs2 = 2 * atof(s2); /* ls3 = atol(s3); /* printf("AS1 = %dn",as1); /* printf("FS2 = %fn",fs2); /* printf("LS3 = %ldn",ls3); /* printf("nPress any key back to program ..."); /* getch(); /*
  • 20.
  • 21. atoi( ) s1 as1 atof( ) s2 fs2 atol( ) s3 long integer ls3 as1, fs2 as3
  • 22. 15 18 19