What will be the output for the following ?code k=0;i=0; while(k<1 && i<1) k=k+1; i=i+1;i=i-k; i=0,k=1 O i=1,k=1 O i=1,k=0 O i=0,k=0 O

Structural Analysis
6th Edition
ISBN:9781337630931
Author:KASSIMALI, Aslam.
Publisher:KASSIMALI, Aslam.
Chapter2: Loads On Structures
Section: Chapter Questions
Problem 1P
icon
Related questions
Question
What will be the output for the following
?code
k=0;i=0;
while(k<1 && i<1)
k=k+1;
i=i+1;i=i-k;
i=0,k=1 O
i=1,k=1 O
i=1,k=0 O
i=0,k=0 O
Transcribed Image Text:What will be the output for the following ?code k=0;i=0; while(k<1 && i<1) k=k+1; i=i+1;i=i-k; i=0,k=1 O i=1,k=1 O i=1,k=0 O i=0,k=0 O
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Work and energy
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, civil-engineering and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Structural Analysis
Structural Analysis
Civil Engineering
ISBN:
9781337630931
Author:
KASSIMALI, Aslam.
Publisher:
Cengage,
Structural Analysis (10th Edition)
Structural Analysis (10th Edition)
Civil Engineering
ISBN:
9780134610672
Author:
Russell C. Hibbeler
Publisher:
PEARSON
Principles of Foundation Engineering (MindTap Cou…
Principles of Foundation Engineering (MindTap Cou…
Civil Engineering
ISBN:
9781337705028
Author:
Braja M. Das, Nagaratnam Sivakugan
Publisher:
Cengage Learning
Fundamentals of Structural Analysis
Fundamentals of Structural Analysis
Civil Engineering
ISBN:
9780073398006
Author:
Kenneth M. Leet Emeritus, Chia-Ming Uang, Joel Lanning
Publisher:
McGraw-Hill Education
Sustainable Energy
Sustainable Energy
Civil Engineering
ISBN:
9781337551663
Author:
DUNLAP, Richard A.
Publisher:
Cengage,
Traffic and Highway Engineering
Traffic and Highway Engineering
Civil Engineering
ISBN:
9781305156241
Author:
Garber, Nicholas J.
Publisher:
Cengage Learning