tritech programming assignment
Write a short application that uses a ‘for’ loop to iterate through 21 cycles (i.e. 0 through 20). With each iteration, the number of the iteration should show to the console window. That was the easy part; now for something more challenging. With each iteration of the ‘for’ loop, tell me if the iteration is an odd number or an even number. Print the words: “ is an odd number” or “ is an even number” after the iteration count. So, the output should look like the following:
0
0 is an even number
1
1 is an odd number
2
2 is an even number … and so forth all the way to 20.
Bonus Problem: Now, I have a bonus problem for you. It is worth 5 extra points on any graded assignment. It may be worth 10 points if you convince me that you solved it on your own and did not ask someone (or the WWW) for the answer. Here is the problem statement:
Prompt the end user for a 7 number sequence password. In your code, the seven number sequence is: 3, 7, 11, 17, 21, 26, 32. The sequence of numbers must be given (input to the console) in this order on the same line. If the sequence of numbers is given correctly, then tell the end user they have gained access to the network. If the end user misses any number – either gets a number wrong, does not input the correct sequence of numbers, or whatever – then two things should happen:
1. An alarm sounds (i.e. a beep will sound 3x). Hint: Beep() is a method in C#
2. You tell the end user that they have entered an incorrect value.
11 years ago 15
Purchase the answer to view it
- cprograming_1.docx
- 1. Describe the cardiovascular system. Begin by first identifying significant anatomical parts and explaining what role each organ plays in the overall system. Then, name important pathology that afflicts those particular anatomical parts just named. A
- Finance homework help
- FIN 534 Final Exam Part 1 and 2
- Accounting
- ECON 545 FINAL EXAM
- SEC 280 Week 5 case study Developing a risk-management policy to mitigate security breaches
- Usefulness
- A plane is doing a parabolic weightless flight to train astronauts. The plane gets up enough speed to shut off its engines when it gets on an arc with radius of 1 km and glide to the top of the semicircle, where the gravity must be zero. What must the vel
- 3 PAGES
- The name of the sculptor who executed the Last Judgement tympanum at Autun Cathedral is