Top

Discussion

What will be the output of the program?

#include
#include

int main()
{
    char *i = "55.555";
    int result1 = 10;
    float result2 = 11.111;
    result1 = result1+atoi(i);
    result2 = result2+atof(i);
    printf("%d, %f", result1, result2);
    return 0;
}

 

  • A.55, 55.555
  • B.66, 66.666600
  • C.65, 66.666000
  • D.55, 55

Answer: C

No answer description available for this question.

No comment is present. Be the first to comment.
Loading…

Post your comment