c code

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

c code

Post by answerhappygod »

c code
C Code 1
C Code 1 (44.62 KiB) Viewed 8 times
Write a main function that performs the following: • Print on the screen your name and surname. On the beginning of a new line print the course name and your section number in the same line and on the beginning of another new line print your student ID. You are allowed to use only one print function, not three!(3 points) • Define an unsigned integer variable N. Prompt the user to enter from the keyboard the sum of all numbers of your student ID. (eg. if your student ID is 62134 than 6+2+1+3+4=16 should be entered and stored in N using the keyboard) (2 points) • Initialize a second unsigned integer control variable i to 1 and using a for loop, find and print all odd numbers less than N. (10 points) • Calculates and prints the average of all odd numbers less than N. You can use an additional control variable for counting all odd numbers less than N. (10 points)
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply