<jupyter_start><jupyter_text>Oops task 1 by using python  <NAME> 20bcs133 problem no.1  leap year one<jupyter_code>def leapyear(year):
  if((year%4!=0) & (year%100!=0) & (year%400!=0)):
     print("entered year is  not a leap year",year)
  else:
     print("Entered year is  a leap year",year)
  
year=int(input("entered a year to check that whether it ia a leap year or not"))
leapyear(year)<jupyter_output>entered a year to check that whether it ia a leap year or not2013
entered year is  not a leap year 2013<jupyter_text>problem no. 2<jupyter_code>def oddeven(num):
  if(num%2!=0):
    print("Weird \n")
  elif(2<=num<=5):
    print("Not Weird \n")
  elif(6<=num<=20):
    print("Weird \n")
  elif(20<num):
    print("Weird \n")
num=int(input("Entered the number"))
oddeven(num)<jupyter_output>Entered the number3
Weird<jupyter_text>problem no.3<jupyter_code>n = int(input("Enter the number of Guests: "))
guests = []

for i in range(0, n):
  name = str(input("Enter the name of Guests: "))
  guests.append(name)
print("Guests are: ", guests)
if(n%2==0):
  for k in range( int((n)/2) , n):
    print("\nFashionable late persons are: ", guests[k])
elif(n%2 != 0):
  for k in range( int((n-1)/2) , n-1):
    print("\nFashionable late persons are: ", guests[k])<jupyter_output>Enter the number of Guests: 6
Enter the name of Guests: tar
Enter the name of Guests: ava
Enter the name of Guests: dj
Enter the name of Guests: dj
Enter the name of Guests: jds
Enter the name of Guests: sfs
Guests are:  ['tar', 'ava', 'dj', 'dj', 'jds', 'sfs']

Fashionable late persons are:  dj

Fashionable late persons are:  jds

Fashionable late persons are:  sfs<jupyter_text>Problem no. 4   search function<jupyter_code>def search_for_keyword(doc_list, keyword):
  req_list = []
  for doc in doc_list:
    duplicate = doc
    duplicate.replace(',','')
    duplicate.replace('.','')
    duplicate_list = duplicate.split()
    for word in duplicate_list:
      if word.lower() == keyword.lower():
        req_list.append(doc)
  
  return req_list

doc_list = ["The Learn Python Challenge Rohit.", "They bought a car", "bangalore"]

keyword = input('Enter the keyword: ')
required_list= search_for_keyword(doc_list, keyword)
print(req_list)

keyword = input('Enter the keyword: ')
required_list = search_for_keyword(doc_list, keyword)
print(req_list)

keyword = input('Enter the keyword: ')
required_list = search_for_keyword(doc_list, keyword)
print(req_list)<jupyter_output><empty_output><jupyter_text>problem no. 5 calculate the gp<jupyter_code>def gp(bp):
  DA = bp*.4
  HRA = bp*.2
  GP = bp+DA+HRA
  return GP
bp=int(input("Entered the basic pay of the employ "))
salary = gp(bp)
print("The GP of the employ is ",salary)<jupyter_output>Entered the basic pay of the employ 12000
The GP of the employ is 19200.0
{'fraction_non_alphanumeric': 0.13299964247407936, 'fraction_numerical': 0.022166607079013228, 'mean_word_length': 4.663967611336032, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 18, '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': '286274', 'license': 'MIT', 'n_tokens_mistral': 1063, 'n_tokens_neox': 1015, 'n_words': 307, 'path': 'oops_task_1.ipynb', 'repo_name': 'Tarunvats9068/oops_with_python', 'size': '2803'}