码迷,mamicode.com
首页 >  
搜索关键字:threading    ( 3244个结果
thread_socket
import socketfrom threading import Threadserver = socket.socket(socket.AF_INET,socket.SOCK_STREAM)server.bind(('127.0.0.1',8080))server.listen(5)# def ...
分类:其他好文   时间:2021-02-02 10:39:57    阅读次数:0
线程执行带有参数的任务
from threading import * from time import * def show_info(name,age): print(name,age) def show_user_info(username,password): print(username,password) if ...
分类:编程语言   时间:2021-01-21 10:50:33    阅读次数:0
C# Redis 帮助类
总结下,后期会陆续更新 using System; using System.Collections.Generic; using System.Linq; using System.Text; using StackExchange.Redis; using System.Threading; u ...
分类:Windows程序   时间:2021-01-18 11:16:13    阅读次数:0
Redis 小测试
一、首先保证redis服务器要开启 二、新建一个控制台进行测试 1、StackExchange.Redis using StackExchange.Redis;using System;using System.Threading; class Program { static Connection ...
分类:其他好文   时间:2021-01-14 11:04:31    阅读次数:0
线程通信-全局变量-标准库threading
from threading import Thread from time import sleep a = 1 def foo(): global a a = 1000 def bar(): sleep(1) print("a = ",a) t1 = Thread(target = foo) t ...
分类:编程语言   时间:2021-01-13 10:50:50    阅读次数:0
Python线程超时控制
# #!/usr/bin/env python # # coding: utf-8 # # https://www.cnblogs.com/scolia/p/6132950.html import threading import time import signal def set_timeout ...
分类:编程语言   时间:2021-01-11 10:54:45    阅读次数:0
7.方法的使用
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; //如果要弹窗。加命名空间 using System.Windows ...
分类:其他好文   时间:2021-01-02 11:27:15    阅读次数:0
8.构造方法
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace _7构造方法 { public class St ...
分类:其他好文   时间:2021-01-02 11:25:25    阅读次数:0
redis 实现分布式锁 和基本锁
1 为什么要使用锁 运行以下代码 # 模拟多线程 import threading def change_it(n): global num for i in range(1000000): num = num + n num = num - n print(num,'555') threass=[ ...
分类:其他好文   时间:2021-01-02 11:13:38    阅读次数:0
多线程与多进程pid的比较
code from threading import Thread from multiprocessing import Process import os def work(name): print('{}的pid是'.format(name), os.getpid()) if __name__ ...
分类:编程语言   时间:2020-12-31 12:09:31    阅读次数:0
3244条   上一页 1 2 3 4 5 6 ... 325 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!