C PROGRAMLAMA (Üçgende hipotenüs hesaplama)


    Programlamaya yeni başlayanlar için C Dilinde başlangıç seviyesinde yazabileceğiniz bir uygulama örneğidir. Bu program üçgenin hipotenüs uzunluğunu bulmanıza yardımcı olacaktır.




#include <stdio.h>
#include <stdlib.h>
#include <math.h> //c dilinde matematiksel işlemler için tanımlanan kütüphane sqrt,pow gibi fonksiyonları barındırır

int main()
{
   float kisak , uzunk, hipo;

    printf("Uzun Kenar Kac cm ? \n cvp = ");
    scanf("%f",&kisak);

    printf("\n Kisa Kenar Kac cm ?\n cvp = ");
    scanf("%f",&uzunk);

    hipo=sqrt(pow(uzunk,2)+pow(kisak,2));

    printf("\n Hipotenus Uzunlugu = %4.2f",hipo);

    getch ();
    return 0;

}




SHARE

Milan Tomic

Hi. I’m Designer of Blog Magic. I’m CEO/Founder of ThemeXpose. I’m Creative Art Director, Web Designer, UI/UX Designer, Interaction Designer, Industrial Designer, Web Developer, Business Enthusiast, StartUp Enthusiast, Speaker, Writer and Photographer. Inspired to make things looks better.

    Blogger Comment
    Facebook Comment

0 yorum :

Yorum Gönder