In a test, a candidate attempted only 8 questions and secured 50% marks in each of the questions. If he obtained a total of 40% in the test and all questions in the test carried equal marks, how many questions were there in the test?
(a) 8 (b) 10 (c) 15 (d) 16