Controlled Loop Homework Help
- May 23, 2017
- Posted by:
- Category: Computer Science QA
Controlled Loop Homework Help
Counter controlled loop
1. Write a program that will use a counter-controlled loop to display the first 50 numbers
2. Modify the program to prompt the user for a number. Starting with that number, use the counter controlled loop to display 50 numbers beginning with the number the user keyed in.
Sentinel Controlled loop
Sentinel controlled loop with numbers
1. Modify the program to prompt the user to input a list of numbers. Display the number enter to the user .To end entering the list in the input the user must enter -1 as the sentinel value that will terminate the loop.
Sentinel controlled loop with strings
2. Modify the program to prompt the user to input a list of names. Display the name enter to the user .To end entering the list in the input the user must enter an * as the sentinel value that will terminate the loop.
EOF controlled loop
1. Modify the above program(Counter Controlled loop) to write on the first 50 numbers to a file name numbers.txt. Afterwards, open the file as an input-file and use the EOF to control your loop.Display the records read from the file to the screen.After the EOF returns the value of true, the loop will terminate
Product Code: CSC06
Looking for Controlled Loop Homework Help, please submit your details here with product code mentioned above.