I don’t understand that why do we need comparator class, because if we are using a templated class T then it should also deal with string datatype ?
Also if we talk about user-defined datatype then will templated class T be able to deal with that or the only option left with us is comparator class ?
