data sufficiency - priya ranks tenth in a class how many students are there in the class i her friend got 58th rank which is the last ii priyas rank from the last is 49th - skillgun

Please read the below given text for solving the question Each question given below has a problem and two statements numbered I and II giving certain information. You have to decide if the information given in the statements is sufficient for answering the problem. Indicate your answer as (a) if the data in the statement I alone is sufficient to answer the question; (b) if the data in the statement II alone is sufficient to answer the question; (c) if the data either in I or II alone are sufficient to answer to question; (d) if the data even in both the statements together are not sufficient to answer the question; (e) if the data in both the statement together are needed.

I reveals that 58th is the last rank in the class.
This means that there are 58 students in the class.
So, I alone is sufficient.
Also, from II, we find that Priya's rank in the class is 10th from the top and 49th from the last.
So there are 58 students in the class.
Thus II alone is sufficient.