码迷,mamicode.com
首页 >  
搜索关键字:struct stat    ( 35365个结果)
协程的使用
asyncio 快速使用 import asyncio async def request(url): print("request正在执行 %s"%url) print("request执行完成 %s"%url) # 创建实践循环 event_loop = asyncio.get_event_lo ...
分类:其他好文   时间:2020-06-24 23:22:54    阅读次数:80
对比c++类的两种成员初始化方式
#include <iostream> using namespace std; struct SData { SData() { std::cout << "default construct" << std::endl; } SData(int value) : a(value) { std:: ...
分类:编程语言   时间:2020-06-24 21:26:50    阅读次数:53
原子性操作原理分析
1. 概念 原子操作是指不被打断的操作,即它是最小的执行单位。最简单的原子操作就是一条条的汇编指令(不包括一些伪指令,伪指令会被汇编器解释成多条汇编指令)。在 linux 中原子操作对应的数据结构为 atomic_t,定义如下: typedef struct { int counter; } ato ...
分类:其他好文   时间:2020-06-24 19:57:50    阅读次数:57
强化学习7日打卡营-世界冠军带你从零实践--基于表格型方法的 RL
强化学习 Reinforce Learning 强化学习区别于机器学习的一点是,强化学习是来做决策的。根据环境的反馈,做出决策。 外界环境情况复杂,和环境的交互主要有 环境的状态 stat、智能体的动作、和对动作带来收益的评价 reward。 这里面涉及2个对象,agent 和 env。 agent ...
分类:其他好文   时间:2020-06-24 19:49:13    阅读次数:65
java拾笔2_异常
catch必须从小类型异常的到大类型异常进行捕捉 catch(FileNotFoundException e){ e.printStackTrace();//输出异常信息 } finally为了保证某一资源一定会释放,所以finally语句中写释放资源的代码: public static void ...
分类:编程语言   时间:2020-06-24 19:31:18    阅读次数:63
算法9:What is the sum of the digits of the number 21000
What is the sum of the digits of the number 21000 public static int sumDigits(int n) { int int_retVal = 0; int int_pow = (int) Math.pow(2, n); String ...
分类:编程语言   时间:2020-06-24 17:51:19    阅读次数:53
c# List深度复制
原文:https://www.cnblogs.com/MRRAOBX/articles/6979479.html 由于List之间的相等的话,等于是把List的地址给赋值过去了,赋值后的List变化,会改变原有的List,并没有起到备份原始数据的作用,对于没有嵌套的List,可以采用遍历重新赋值的方 ...
分类:Windows程序   时间:2020-06-24 15:48:30    阅读次数:126
Nginx-日志分析
##日志格式 '$remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" "$http_x_forwarded_for"' 首先把字 ...
分类:其他好文   时间:2020-06-24 14:24:57    阅读次数:55
static inline extern等概念
写驱动时碰到如下函数调用,涉及知识点 static inline extern include/of.h中有如下定义: extern struct device_node *of_find_node_by_name(struct device_node *from, const char *name ...
分类:其他好文   时间:2020-06-24 13:54:37    阅读次数:62
LockSupport的用法及原理
已剪辑自: https://www.jianshu.com/p/f1f2cd289205 是什么 LockSupport是一个线程阻塞工具类,所有的方法都是静态方法,可以让线程在任意位置阻塞,当然阻塞之后肯定得有唤醒的方法。 有什么用 接下面我来看看LockSupport有哪些常用的方法。主要有两类 ...
分类:其他好文   时间:2020-06-24 13:39:21    阅读次数:84
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!