Question: 2:56 sce.carleton.ca Submit your two files lab21.cmwn and lab22.cnun as lab #2 for your lab section to prove your attendance at the lab. Both files

 2:56 sce.carleton.ca Submit your two files "lab21.cmwn" and "lab22.cnun" as lab

2:56 sce.carleton.ca Submit your two files "lab21.cmwn" and "lab22.cnun" as lab #2 for your lab section to prove your attendance at the lab. Both files must be submitted at the same time. As long as they are in the same folder, when you select "lab21.cmm" the submit program will find them both. If you click 00 Fido submit" and there are still files missing, you will be asked to add the missing filels create three variables: mumber, x0, and x output "Enter a number. read a value into nmber set x0 to 1 set xl to 0.5mumber) while (the absolute value ofx-x0 is more than 0.00001 [see note below]) do set x0 to x set x to 0.3 (xl+(nimberxI)) endwhile output "The square root of", the value of mumber, "is" the value of xI, and an endl Note: to write "the absolute value of xl -x0 is more than 0.00001" in C- use fabs(x1 x0)> 0.00001 Single stepping is both a useful debugging tool and a good way for beginners to gain a better understanding of how computer programs are executed. The basic idea is that the program is executed one step at a time. This allows the programmer to follow the process and observe every change in variable values To single step through a program, select "step through" from the "execute" menu. At each step of the execution process an (go on to next step), "run" (begin executing continuously) and "stop" (stop executing altogether) Except when program input is required, it is only necessary to keep on selecting "step" in order to single step through an entire program. explanatory message is displayed and the user is gi given the choice of step Single stepping through an entire program rapidly becomes unattractive as programs become larger. Usually single stepping is restricted to those parts of a program where problems are suspected. This particular program, however, is sufficiently short that single stepping through all of it is quite practical. Do this. When input is required enter"3" (don't forget to hit ENTER) in the input/output window. Once this has been done the input output window should be minimized or just moved out of the way Algorithm: create two variables: mber and divider output "Enter a number: read a value intonumber Output The binary equivalent of ".value of mumber, and"is

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

To solve these problems lets break down the tasks in steps 1 Finding the Square Root of a Number Thi... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!