۱۳۸۹ آبان ۲۲, شنبه

توان

با استفاده ازین سورس میتوانید عدد اولی را به توان دومی برسانید
#include <stdio.h>
#include <conio.h>
#include <math.h>
 void main()
 {
  int x,y;
  double z;
  printf("please enter frest number:");
  scanf("%d", &x);
  printf("please enter secend number:");
  scanf("%d", &y);
  z = pow ( x, y);
  printf("total: %lf", z);
  getch();
 }

هیچ نظری موجود نیست:

ارسال یک نظر