Skip to content

Find the index of the first occurrence in a string. (String Problem) #3323

Description

@kanikarajpal

This is a(n):

  • New algorithm
  • Update to an existing algorithm
  • Error
  • Proposal to the Repository

Details:
I would like to add a solution to a problem- Find the index of the first occurrence in a string. (Leetcode Problem) (Python).

Description -
Given two strings needle and haystack, return the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.

Link -
https://leetcode.com/problems/find-the-index-of-the-first-occurrence-in-a-string/

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions