Skip to main content
Engineering LibreTexts

31.3: Chapter 7

  • Page ID
    35925
  • Problem 1: Solution

    if(X<0)
        printf("negative value");
    

    Problem 3: Solution

    // This assumes the variables are integers
    if(X>Y)
        printf("%d",X);
    else
        printf("%d",Y);
    

    Problem 5: Solution

    for(i=0;i<6;i++)
        printf("Error!");
    

    Problem 7: Solution

    for(R=100;R<=200;R+=5)