Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please use only use a WHILE loop for this problem, and NOT a for loop. Please use Python 2.7, and make sure it passes ALL

Please use only use a WHILE loop for this problem, and NOT a "for" loop. Please use Python 2.7, and make sure it passes ALL test cases, provided below beneath the answer template for this problem.

Problem Write code that takes two strings from the user, and sees if all the letters in the second string appear in the first, in order. For example, happybirthday and apt yields the result True, while happybirthday and htb yields the result False.

Answer Template

#PROBLEM 2 def checkIn(l1,l2): string1 = l1 string2 = l2 #YOUR CODE GOES HERE (indented) return string1 #END YOUR CODE

Here are the Test Cases

checkIn bird c

False

checkIn bird i True checkIn bird ir True checkIn bird bd True checkIn bird db False checkIn birkugyfjydhrsfbdsd bkujds True checkIn birkugyfjydhrsfbdsd bkjuds False 

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 10g Insider Solutions

Authors: Arun R. Kumar, John Kanagaraj, Richard Stroupe

1st Edition

0672327910, 978-0672327919

More Books

Students also viewed these Databases questions