Asked by Meron
Assume that a computer is to decide whether a student passes or fails based on the average marks obtained in 5 subjects. A student passes if the average mark is 50 or above. Identify the input,processing&output of this operation.
Answers
Answered by
MathMate
1.Input marks and store in a[0] to a[4].
2.Calculate average using a for-loop.
3. Decide (using an if-statement) if the student passes according to the given criterion.
4. Output marks and status (pass or fail).
2.Calculate average using a for-loop.
3. Decide (using an if-statement) if the student passes according to the given criterion.
4. Output marks and status (pass or fail).
Answered by
fera
the in put is their mark,the processing is dividing the marks to the total number of the subject,the output is the average.
There are no AI answers yet. The ability to request AI answers is coming soon!