3

SDE Sheet - Minimum indexed character

 8 months ago
source link: https://www.geeksforgeeks.org/videos/sde-sheet-minimum-indexed-character/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Minimum indexed character

December 28, 2023 |320 Views
SDE Sheet - Minimum indexed character
SDE Sheet, GFG SDE Sheet, String
 Save  Share  2 Likes
Description
Discussion

This is a part of String section under GFG SDE Sheet. 

In this video, we are given, a string str and another string patt. Find the minimum index of the character in str that is also present in patt.

Example :

Input:
str = geeksforgeeks
patt = set
Output: 1

Explanation: e is the character which is present in given str "geeksforgeeks" and is also present in patt "set". Minimum index of e is 1. 

Try it out before watching the implementation of the problem in the video. We recommend watching the video, even if you can solve the problem. You may discover something new. All the best!!!

Do check out:-
Article: https://www.geeksforgeeks.org/find-character-first-string-present-minimum-index-second-string/
Problem: https://www.geeksforgeeks.org/problems/minimum-indexed-character-1587115620/1
SDE Sheet Link: https://www.geeksforgeeks.org/sde-sheet-a-complete-guide-for-sde-preparation/

Read More

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK