test for NDEBUG

#include <stdio.h>
#include <stdlib.h>
#define NDEBUG
#include <assert.h>
#include <math.h>
int main(void)
{
    float fa, fb, fc;
    puts("intput fa and fb, 0 0 to stop.");
    while (2 == scanf("%f %f", &fa, &fb) && (fa || fb) != 0)
    {
          fc = fa * fa - fb * fb;
          assert(fc >= 0);   
          printf("the answer is %f\n", sqrt(fc));
          puts("the nexe numbers:");
    }
    puts("Done");
    system("pause");
    return 0;
}

你可能感兴趣的:(职场,休闲)