Users are required to enter two integer numbers 'x' and 'y' (x < y) using the keyboard (STDIN).
The system displays the sum value of the numbers from x to y.
Below is an example of how the program will run:
Enter the value 5 for 'x' and 15 for 'y'.
5
15
OUTPUT:
110
Press any key to continue
Question 3:
(1 mark, file to be edited: Q3.c)
Your program allows the user to enter an array of 'n' integer numbers, where 'n' is entered from the keyboard (STDIN).
Program to print the even numbers sorted in ascending order. There is a newline character '\n' between any two printed numbers.
Below is an example when 'n' = 6; elements: {2, -4, 5, 8, 15, 0}
Close
+ 100%
Zoom