import time
import logging
import multiprocessing
def sleep_5_seconds():
logging.info(' Will sleep 5 seconds')
time.sleep(5)
logging.info(' Done sleeping 5 seconds')
def sleep_10_seconds():
logging.info(' Will sleep 10 seconds')
time.sleep(10)
logging.info(' Done sleeping 10 seconds')
def main():
logging.basicConfig(level = logging.INFO)
PROCESS1 = multiprocessing.Process(target = sleep_5_seconds)
PROCESS2 = multiprocessing.Process(target = sleep_10_seconds)
PROCESS1.start()
PROCESS2.start()
main()OUTPUT:
INFO:root: Will sleep 5 seconds
INFO:root: Will sleep 10 seconds
After 5 seconds
INFO:root: Done sleeping 5 seconds
After another 5 seconds
INFO:root: Done sleeping 10 seconds

Sometimes, we might be in a situation where we have to send emails to multiple people in a personalised manner (like mailing each student their grades, mailing bank statements to customers, etc.). Although these emails follow the same format, the information inside it varies from receiver to receiver. When done…


Almost every interview for coding and software development roles is incomplete without a programming interview. There are thousands of questions in coding sites like LeetCode and it is impossible to cover all the topics within a short period.

In this series, I will provide solutions to frequently asked interview questions…


“When was the last time you tried a coding challenge?”

“I tried it just yesterday and it’s way out of my league. I’m just a beginner.” said the apprentice.

“About a year ago, when I began learning about stacks, trees and heaps. Now, I’m all caught building websites.”


Photo by Glenn Carstens-Peters on Unsplash

Netflix began its journey to becoming the world’s biggest streaming service in 1997.

Initially, Netflix offered DVD sales and rental by mail. In 2007, Netflix began its streaming media services as the world’s first online DVD rental store with 925 titles. …

Madhumitha Kannan

I’m a Computer Science Undergrad on a quest to innovate and build stuff with code. Find all my posts at https://madhumithakannan.github.io/blog

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store