include int main(){ int a, b=3; double x=5.0, y; for (a=1; a -2) { b=b-a; printf ("%d%d\n", a, b); } x=x-b; y=b%a; } printf ("%3.1If\n",a+b+x+y); return (0); }

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter5: Control Structures Ii (repetition)
Section: Chapter Questions
Problem 14PE
icon
Related questions
Question
What will be the exact output of y in this program?
include<stdio.h>
int main(){
int a, b=3;
double x=5.0, y;
for (a=1; a<b; ++a) {
if (b > -2) {
b=b-a;
printf ("%d%d\n", a, b);
}
X=x-b;
y=b%a;
}
printf ("%3.1If\n",a+b+x+y);
return (0);
}
Transcribed Image Text:What will be the exact output of y in this program? include<stdio.h> int main(){ int a, b=3; double x=5.0, y; for (a=1; a<b; ++a) { if (b > -2) { b=b-a; printf ("%d%d\n", a, b); } X=x-b; y=b%a; } printf ("%3.1If\n",a+b+x+y); return (0); }
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Mathematical functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning