Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Q1. Write a sequential C code that reads 4 integers from the user and then prints their average along with how many integers are above

image text in transcribed

Q1. Write a sequential C code that reads 4 integers from the user and then prints their average along with how many integers are above average. (8 marks) Sample run1 (green text is user input): Enter 4 integers separated by spaces: 1 2 3 10 There is 1 entry above the average which is 4. Sample run2 Enter 4 integers separated by spaces: 2 478 There are 2 entries above the average which is 5.3 Marking Guide: +2 for reading integers, +2 for finding sum and avg, +4 for counting and printing results

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions