import sys
import bisect
def suffixQueries(S, query):
suffixes = [S[i:] for i in range(len(S))]
suffixes.sort()
total = 0
for q in query:
i = bisect.bisect_left(suffixes, q)
if i < len(suffixes) and suffixes[i].startswith(q):
total += len(suffixes[i])
else:
total += 0
return total % (10**9 + 7)
def main():
N = int(sys.stdin.readline().strip())
Q = int(sys.stdin.readline().strip())
S = sys.stdin.readline().strip()
query = [sys.stdin.readline().strip() for _ in range(Q)]
ans = suffixQueries(S, query)
print(ans)
if __name__ == "__main__":
main()
Suffixquiress β
Epam Slots are available
@Mrtrueliving_ix @Mrtrueliving_ix
Review:
https://t.me/Code_alphix/8410?single
Those who need Test Clearance π―
Successfully cleared Virtusa Hackthon β
Shortlist for Technical interview ππ»
Test accomplished β€οΈ || with π― success Rate
R2:https://t.me/Code_alphix/8407?single
@Mrtrueliving_ix @Mrtrueliving_ix
#Virtusa #Hackthon #Interview #SDE
Shortlist for Technical interview ππ»
Role : software developer Engineer
Test accomplished β€οΈ || with π― success Rate
R2:https://t.me/Code_alphix/8407?single
DM for any placement Help available
@Mrtrueliving_ix @Mrtrueliving_ix
#Virtusa #Hackthon #Interview #SDE
β€3
β οΈ Donβt Waste Your Time & Money on the Wrong People! π‘
These days, many claim to help β but not everyone truly wants to see you grow.
Some only care about payment, while real mentors care about your progress and success.
π― Choose wisely!
Find mentors who guide you with honesty, support you with patience,
and push you toward your goals with real dedication.
πͺ The right guidance can change your career.
The wrong one can cost you both your time and your confidence.
β¨ Invest in people who invest in you.
Because when you learn from the right hands β success is guaranteed! π
β€οΈ Yours truly β @Mrtrueliving_ix & His Team π»
ultimate success is guaranteed! π
#ChooseWisely #TrueGuidance #SmartLearning #TeamTrueLiving #SuccessWithPurpose
β€1
π Company : ShareChat
Role : SDE Intern
Eligible Batches : 2025, 2026 Graduates
Stipend : βΉ50K per month
Location : Bangalore
Duration : 6 Months
πApply Link :
https://www.linkedin.com/jobs/view/4333740347
Role : SDE Intern
Eligible Batches : 2025, 2026 Graduates
Stipend : βΉ50K per month
Location : Bangalore
Duration : 6 Months
πApply Link :
https://www.linkedin.com/jobs/view/4333740347
Test mail confirm
Linkedin
ShareChat hiring SDE-Intern in Bengaluru, Karnataka, India | LinkedIn
Posted 12:52:11 PM. Who are we and What do we do?
ShareChat (https://sharechat.com/about) is India's largest Profitableβ¦See this and similar jobs on LinkedIn.
ShareChat (https://sharechat.com/about) is India's largest Profitableβ¦See this and similar jobs on LinkedIn.
β€2
*ππ₯ SoftSuave Software Tech OFF Campus Hiring 2025 β Freshers Only Active link Apply Now*
*π Role:* Software Developer (Freshers)
*π Eligibility:* B.E./B.Tech/M.E./M.Tech/MCA/BCA/B.Sc CS graduates of 2023, 2024 & 2025 with strong logical and analytical thinking
*π‘ Interview Process:*
β’ Level 1: Online MCQ
β’ Level 2 & 3: Programming Test
β’ Level 4: Technical Interview
*π° Salary:* βΉ25,000 β βΉ38,000 (Expected)
*β³ Last Date:* 7th Nov 2025
Apply link :-
https://www.naukri.com/job-listings-software-engineer-trainee-0-1y-fresher-java-python-soft-suave-chennai-0-to-1-years-021125002292?utmcampaign=androidjd&utmsource=share&src=sharedjd
*π Role:* Software Developer (Freshers)
*π Eligibility:* B.E./B.Tech/M.E./M.Tech/MCA/BCA/B.Sc CS graduates of 2023, 2024 & 2025 with strong logical and analytical thinking
*π‘ Interview Process:*
β’ Level 1: Online MCQ
β’ Level 2 & 3: Programming Test
β’ Level 4: Technical Interview
*π° Salary:* βΉ25,000 β βΉ38,000 (Expected)
*β³ Last Date:* 7th Nov 2025
Apply link :-
https://www.naukri.com/job-listings-software-engineer-trainee-0-1y-fresher-java-python-soft-suave-chennai-0-to-1-years-021125002292?utmcampaign=androidjd&utmsource=share&src=sharedjd
π§ Assessment Structure (6 Parts)
1οΈβ£ Verbal Reasoning β 15 Qs | 18 mins
2οΈβ£ Logical Reasoning β 15 Qs | 18 mins
3οΈβ£ Quantitative Aptitude β 15 Qs | 18 mins
4οΈβ£ Analytical Reasoning β 15 Qs | 18 mins
5οΈβ£ Critical Reasoning β 15 Qs | 18 mins
6οΈβ£ HackerRank (Coding Section)
β±οΈ The test will auto-submit once time ends.
1οΈβ£ Verbal Reasoning β 15 Qs | 18 mins
2οΈβ£ Logical Reasoning β 15 Qs | 18 mins
3οΈβ£ Quantitative Aptitude β 15 Qs | 18 mins
4οΈβ£ Analytical Reasoning β 15 Qs | 18 mins
5οΈβ£ Critical Reasoning β 15 Qs | 18 mins
6οΈβ£ HackerRank (Coding Section)
β±οΈ The test will auto-submit once time ends.
Hcl ONCAMPUS test pattern β
β€1
π― infosys ONCAMPUS TEST UPDATE
π© Test credentials have already been sent to everyone who has the ONCAMPUS test.
β οΈ If youβre planning to write the test from home, donβt take the risk.
π Before the test starts, you must enter the Test Admin Password β only then the test will begin.
π Note: The Admin Password is different for each college.
π« All the best from the Codeicon Family!
β @Mrtrueliving_ix
β€1
All Placement Exam's Help Available
@Mrtrueliving_ix @Mrtrueliving_ix
πΌ ACCENTURE (2026 Batch ONCAMPUS) β Previous Helping Proofs πͺ
β
Genuine Support β Real Results
π° By @Mrtrueliving_ix & Team
π Proof Links (Only 2026 Batch OnCampus):
πΉ https://t.me/Code_alphix/8565?single
πΉ https://t.me/Code_alphix/8537
πΉ https://t.me/Code_alphix/8539
πΉ https://t.me/Code_alphix/8565?single
πΉ https://t.me/Code_alphix/8569?single
πΉ https://t.me/Code_alphix/8488?single
πΉ https://t.me/Code_alphix/8313
π¬ We donβt show fake proofs β only real helping records!
π Choose the right mentor for guaranteed success.
@Mrtrueliving_ix @Mrtrueliving_ix
#Accenture2026 #OnCampus #MrTrueliving #CodeAlphix #SuccessProofs
Weβre excited to announce a referral opportunity for fresh graduates to join our US Staffing Team! ππΌ
This is a wonderful chance to help young professionals start their careers with V-Soft while contributing to our growing and dynamic team. π
π Eligibility Criteria:
β’ Education: B.Tech / B.Sc / B.Com / MBA
β’ Excellent communication & interpersonal skills
β’ Strong interest in recruitment and staffing
β’ Willingness to work in night shifts π
π Interview Timings:
Effective from tomorrow | 7:30 PM IST
π§ To Refer / Apply:
Send profiles to π
Letβs bring in talented individuals who can grow with us! πͺ
This is a wonderful chance to help young professionals start their careers with V-Soft while contributing to our growing and dynamic team. π
π Eligibility Criteria:
β’ Education: B.Tech / B.Sc / B.Com / MBA
β’ Excellent communication & interpersonal skills
β’ Strong interest in recruitment and staffing
β’ Willingness to work in night shifts π
π Interview Timings:
Effective from tomorrow | 7:30 PM IST
*Location: Hyderabad*
Mode: Face-to-face
π§ To Refer / Apply:
Send profiles to π
Schiluka@vsoftconsulting.com
Letβs bring in talented individuals who can grow with us! πͺ
π» Virtusa Hackathon Interview Experience π
interview tested both coding clarity and conceptual understanding in depth π‘
π§© Topics covered:
Custom Exceptions (implementation)
Database Normalization (1NF β 3NF)
Memory Management of Primitives & Non-Primitives (with diagrams)
Concepts explained using Paint app π¨
Strings, StringBuilder, StringBuffer & String Pool
Upcasting & Downcasting
Threads & their lifecycle
One code from our Hackathon exam π§
π’ Verdict: Shortlisted for HR Interview π
β€2
Upcoming All company Exams Help available
DM @Mrtrueliving_09 @Mrtrueliving_09
Those who need π― test Clearance β€οΈ
DM @Mrtrueliving_09 @Mrtrueliving_09
Those who need π― test Clearance β€οΈ
Hcl ONCAMPUS || Test accomplished β€οΈ
DM for any placement Help
@Mrtrueliving_09 @Mrtrueliving_09
#Hcl #ONCAMPUS #R1
All sections are done along with coding π
β€1π₯1