Question: 24. When we create a method that reads from or prints to a file, we need to include the words throws Exception to the header.

24. When we create a method that reads from or prints to a file, we need to include the words "throws Exception" to the header. Why do we need to include these keywords? (2 marks) 25. Describe the meaning of cohesion, in terms of writing classes. Give an example of why cohesion is important (3 marks). 26. Briefly describe the concept of information hiding. (2 marks) 27. What is the difference between a method which is static and one which is not static? (1 mark)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
