You have three compulsory problems and one optional problem for this lab. The optional problem is for your practice and will not be graded. However, it is recommended that if you have sufficient time then you must attempt the optional problem. The optional problem is relatively tough as compared to the other three problems. 1. (30 marks) Write a program that takes three numbers as input from the user and finds out whether one of the three numbers is the arithmetic mean of the other two. For example: Input: 7,15,11 Output: 11 is the mean of 7 and 15 Input: 27,23,31 Output: 27 is the mean of 23 and 31 Input: 7,8,10 Output: No number is mean of the other two 2. (40 marks) Write a program that takes a positive integer in the range 1 to 365 (which corresponds to the day of the year) as input and outputs the day of the week. Assume that day 1 is Sunday. Make use of the switch statment. For example: Input: 16 Output: Monday Input: 26 Output: Thursday Input: 172 Output: Wednesday 3. (40 marks) Write a program that takes a number as input from the user and outputs the sum of digits of that number. For example: Input: 4678 Output: 25 (4+6+7+8=25) Input: 19029 Output: 21 (1+9+0+2+9=21) Optional Problem: The proper divisors of an integer n are defined as the positive divisors of n other than n itself. For example the proper divisors of 10 are 1, 2 and 5. A number is called a Perfect Number if the summation of all of its proper divisors is equal to the number itself. For example, 6 and 28 are perfect numbers because 1 + 2 + 3 = 6 and, 1 + 2 + 4 + 7 + 14 = 28. Write a program that takes a number n as input and outputs whether the given number is a perfect number or not. Hint: In the while loop store the sum of all the divisors encountered till that point.