<jupyter_start><jupyter_text>**Question 1:**Please write a program using generator to print the numbers which can be divisible by 5 and7 between 0 and n in comma separated form while n is input by console.Example:If the following n is given as input to the program:100Then, the output of the program should be:0,35,70 **Answer:**<jupyter_code>n = int(input("Please input n: "))

def print_numbers(n):
    number_list = []
    for i in range(n):
        if i % 5 == 0 and i % 7 == 0:
            number_list.append(str(i))
        else:
            pass
    yield ', '.join(number_list)
        
for i in print_numbers(n=n):
    print(i)<jupyter_output>Please input n: 100
0, 35, 70<jupyter_text>**Question 2:**Please write a program using generator to print the even numbers between 0 and n in commaseparated form while n is input by console.Example:If the following n is given as input to the program:10Then, the output of the program should be:0,2,4,6,8,10 **Answer:**<jupyter_code>n = int(input("Please input n: "))

def print_even_numbers(n):
    number_list = []
    for i in range(n+1):
        if i % 2 == 0:
            number_list.append(str(i))
        else:
            pass
    yield ', '.join(number_list)
        
for i in print_even_numbers(n=n):
    print(i)<jupyter_output>Please input n: 10
0, 2, 4, 6, 8, 10<jupyter_text>**Question 3:**The Fibonacci Sequence is computed based on the following formula:f(n)=0 if n=0f(n)=1 if n=1f(n)=f(n-1)+f(n-2) if n>1Please write a program using list comprehension to print the Fibonacci Sequence in commaseparated form with a given n input by console.Example:If the following n is given as input to the program: 7Then, the output of the program should be:0,1,1,2,3,5,8,13 **Answer:**<jupyter_code>n = 7

def fib_seq(n):
    if n == 0:
        return 0
    elif n == 1:
        return 1
    else:
        return fib_seq(n-1) + fib_seq(n-2)
    
print(', '.join([str(fib_seq(i)) for i in range(8)]))<jupyter_output>0, 1, 1, 2, 3, 5, 8, 13<jupyter_text>**Question 4:**Assuming that we have some email addresses in the "<EMAIL>" format,please write program to print the user name of a given email address. Both user names andcompany names are composed of letters only.Example:If the following email address is given as input to the program:<EMAIL>Then, the output of the program should be:john **Answer:**<jupyter_code>import re

email_address = "<EMAIL>"
re.findall(r'([aA-zZ]+)\@', email_address)[0]<jupyter_output><empty_output><jupyter_text>**Question 5:**Define a class named Shape and its subclass Square. The Square class has an init functionwhich takes a length as argument. Both classes have a area function which can print the areaof the shape where Shape's area is 0 by default. **Answer:**<jupyter_code>class Shape():
    def __init__(self):
        pass
    
    def area(self):
        return 0
    
class Square(Shape):
    def __init__(self, length):
        self.length = length
        
    def area(self):
        return self.length ** 2
        
shape = Shape()
print(shape.area())

square = Square(length=2)
square.area()<jupyter_output>0
{'fraction_non_alphanumeric': 0.10993249758919961, 'fraction_numerical': 0.02892960462873674, 'mean_word_length': 3.6378539493293593, 'pattern_counts': {'":': 0, '<': 20, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '5', 'dir': 'jupyter-structured-clean-dedup', 'id': '416216', 'license': 'MIT', 'n_tokens_mistral': 1074, 'n_tokens_neox': 992, 'n_words': 370, 'path': 'Python Programming Basic Assignment - Assignment15.ipynb', 'repo_name': 'VaheC/Python_assigments', 'size': '3144'}