Is Subsequence Problem

Is Subsequence Problem — ExecCode Easy DSA Practice

Solve the Is Subsequence problem on ExecCode. Free online easy DSA practice in Arrays - Basics. Write and run code in Java, C++, Python — no signup required to run.

Problem description

Given s and t, return true if s is a subsequence of t. For Is Subsequence, focus on the exact input variables, return only the requested value, and preserve the required time complexity for the intended pattern.

Examples

Input s = "abc", t = "ahbgdc"; Output true

Constraints

1 ≤ n ≤ 10^5 Values fit interview constraints

Practice Is Subsequence free on ExecCode. Browse DSA problems, topic map, and placement guides.