<jupyter_start><jupyter_text>Question 1:Remove the hardcoded part from the code with the help of configparserUse the file config file exc.inifrom configparser import ConfigParserimport socketprint (socket.gethostbyname_ex(socket.gethostname())[-1])config = ConfigParser()config.read("letus.ini")http_ip = config.get("HTTP", "IP")http_port = config.getint("HTTP", "port")print ("http ip", http_ip)print ("http port", http_port, type(http_port))<jupyter_code>import configparser

config = configparser.ConfigParser()
config.read('db.ini')

sections = config.sections()
print(f'Sections: {sections}')

sections.append('sqlite')

for section in sections:

    if config.has_section(section):
      print(f'Config file has section {section}')
    else:
      print(f'Config file does not have section {section}')<jupyter_output>Sections: []
Config file does not have section sqlite
{'fraction_non_alphanumeric': 0.1232876712328767, 'fraction_numerical': 0.00228310502283105, 'mean_word_length': 6.626086956521739, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, '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': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '254468', 'license': 'Apache-2.0', 'n_tokens_mistral': 269, 'n_tokens_neox': 268, 'n_words': 70, 'path': 'DAY 13 ASSIGNMENT.ipynb', 'repo_name': 'gkumarashish213/Letsupgrade-advance-python-day-13', 'size': '876'}