Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

2 functions at a time py

from threading import Thread

def fun1():
    print("Working1")
def fun2():
    print("Working2")

Thread(target=fun1).start()
Thread(target=fun2).start()
Comment

2 functions at a time py


from threading import Thread

def func1():
    print('Working')

def func2():
    print("Working")

if __name__ == '__main__':
    Thread(target = func1).start()
    Thread(target = func2).start()

Comment

PREVIOUS NEXT
Code Example
Python :: speak by a discord bot in python 
Python :: dates and times in python 
Python :: bar chart in python 
Python :: turtle screen 
Python :: exception logging 
Python :: How to take multiple inputs in one line in python using list comprehension 
Python :: how to install pywhatkit in pycharm 
Python :: no exception message supplied django template 
Python :: Using replace() method to remove newlines from a string 
Python :: compiling python code 
Python :: how to divide string in python 
Python :: spacy french stopwords 
Python :: stackoverflow python 
Python :: python add new key to dictionary 
Python :: shared SHMEM python 
Python :: discord.py send message to channel with mutiple id 
Python :: how to use custom activity in discord.py 
Python :: Display shape of the DataFrame 
Python :: program python factorial 
Python :: accumulator programming python 
Python :: python append to tuple list 
Python :: mountain array leetcode 
Python :: importing time and sleep. python 
Python :: change creation date filesystem py 
Python :: Selenium get response body python 
Python :: decorators in python 
Python :: ImportError: sys.meta_path is None, Python is likely shutting down 
Python :: authentication serializer drf 
Python :: python turtle 
Python :: Set path for another directory 
ADD CONTENT
Topic
Content
Source link
Name
9+6 =