Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. Site Bugs / Suggestions
  4. how to splve this question

how to splve this question

Scheduled Pinned Locked Moved Site Bugs / Suggestions
tutorialquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rushikesh kulkarni 2023
    wrote on last edited by
    #1

    Given a string Str and a character C, your task is to remove the first and last occurrence of the character C from the string Str.

    Input Format

    • First line of input consists of a string value, denoting str

    Second line of input consists of a character denoting C

    Constraints

    • 1 <= str.length <=100

    Output Format

    • Print the string after the above operation

    Sample Input

    codedecode

    Sample Output

    coddecod

    Richard DeemingR 1 Reply Last reply
    0
    • R Rushikesh kulkarni 2023

      Given a string Str and a character C, your task is to remove the first and last occurrence of the character C from the string Str.

      Input Format

      • First line of input consists of a string value, denoting str

      Second line of input consists of a character denoting C

      Constraints

      • 1 <= str.length <=100

      Output Format

      • Print the string after the above operation

      Sample Input

      codedecode

      Sample Output

      coddecod

      Richard DeemingR Offline
      Richard DeemingR Offline
      Richard Deeming
      wrote on last edited by
      #2
      1. You have posted this in the forum for discussing bugs and suggestions for the CodeProject site itself. 2) You have also already posted this in QA: How to solve this question[^] 3) Nobody here is going to do your homework for you.

      "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

      "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups