<jupyter_start><jupyter_text>Assignment 1<jupyter_code>! pip install pylint
%%writefile prime.py
'''
it is a prime number checking program file
'''
def primeornot(num):
    '''This function checks whether given number is prime or not'''
    if num > 1:
        for i:
            for i in range(2,num):
                if num%i == 0:
                    print(num,"Not prime")
                    break
                else:
                    print(num,"is a prime number")
                    
import prime
prime.primeornot
def primeornot(num):
    '''
    This function checks whether given number is prime or not
    '''
    if num > 1:
         for i in range(2,num):
                if num%i == 0:
                    print(num,"Not prime")
                    break
                else:
                    print(num,"is a prime number")
                    break
primeornot(7)
primeornot(8)<jupyter_output>8 Not prime<jupyter_text>Assignment 2<jupyter_code>lower = int(input("Enter lower range: "))
upper = int(input("Enter upper range: "))
 
for num in range(lower,upper + 1):
   # initialize sum
   sum = 0
  
   temp = num
   while temp > 0:
       digit = temp % 10
       sum += digit ** 3
       temp //= 10
 
   if num == sum:
       print(num)<jupyter_output>Enter lower range: 1
Enter upper range: 1000
1
153
370
371
407
{'fraction_non_alphanumeric': 0.09858103061986558, 'fraction_numerical': 0.027632561613144136, 'mean_word_length': 1.757201646090535, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 10, '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': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '405410', 'license': 'Apache-2.0', 'n_tokens_mistral': 436, 'n_tokens_neox': 392, 'n_words': 131, 'path': 'Day 9 Assignment 1 & 2.ipynb', 'repo_name': 'CresiDaniel/LetsUpgrade-Python-B7', 'size': '1339'}