Suffix queries

Problem Name:
Suffix queries
Site:HackerEarth
Links:
Tags: