Friday, February 1, 2019

Insider Threat

  • Problem Description

    Write a Python program to find the substring in the given string

    Refer sample input and output for formatting specification.

    All float values are displayed correct to 2 decimal places.

    All text in bold corresponds to input and the rest corresponds to output

    Input:
    1. Sentence
    2. The word to be searched

    Output:
    Case 1: If the string is present then print "Substring in string"
    Case 2: If the string is not present then print "Substring not found in string"
  • CODING ARENA
  • a=input()
    b=input()
    if(b in a):
        print("Substring in string")
    else:
        print("Substring not found in string")
  • Test Case 1

    Input (stdin)
    TAMIL THE FIRST LANGUAGE IN WORLD
    
    TAMIL
    
    
    Expected Output
    Substring in string
  • Test Case 2

    Input (stdin)
    TAMIL THE FIRST LANGUAGE IN WORLD
    
    ENGLISH
    
    
    Expected Output
    Substring not found in string

No comments:

Post a Comment