@Sunkumsav you can use stl lowerbound and upperbound functions if you want
i am not getting it https://ide.codingblocks.com/s/299187
@Sunkumsav correct code only wrong input corrected