Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please answer the following questions in basic python code. Please use comments where necessary. 6. input: a string with character in it, a string with

Please answer the following questions in basic python code. Please use comments where necessary.

6. input: a string with character in it, a string with numbers in it output: go through the two strings together. At index i, if the number in str2 is even, put the letter in str1 into evenStr if the number is odd, put the letter into oddStr. Return the even/odd strings Sample: "helloworld" "2435232399" gives evenStr="heoo" oddStr="llwrld" ''' #def two_strings(str1,str2)

7. The number 6 is a truly great number. Given two int values, a and b, return True if either one is 6. Or if their sum or difference is 6. Note: the function abs(num) computes the absolute value of a number.

love6(6, 4) returns True love6(4, 5) returns False love6(1, 5) returns True ''' #def love6(a,b):

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

Conceptual Database Design An Entity Relationship Approach

Authors: Carol Batini, Stefano Ceri, Shamkant B. Navathe

1st Edition

0805302441, 978-0805302448

More Books

Students also viewed these Databases questions