JAVA: public final int numWaterBottles(int numBottles, int numExchange) { int re = numBottles, empty = numBottles; while (empty >= numExchange) { int ...
分类:
其他好文 时间:
2021-05-24 03:39:54
阅读次数:
0
1.使用虚拟目录是,后端中的重定向等该如何处理 string path = filterContext.HttpContext.Request.ApplicationPath; if (path == "/") { path = ""; } filterContext.Result = new Re ...
分类:
Web程序 时间:
2021-05-24 01:38:02
阅读次数:
0
''' ! Creat Date: 2021-5-4 ! Author: xdd1997 ! Email: xdd2026@qq.com ''' import re # 输入文件 # 接口 filePath = 'D:\\Desktop\\uu.lis' 也可以 filePath = r'D:\De ...
分类:
编程语言 时间:
2021-05-24 00:13:27
阅读次数:
0
自定义封装多个回调函数的执行 <script src="./Promise.js"></script> let p = new Promise((resolve, reject) => { setTimeout(() => { resolve('ok'); }, 1000) }) p.then(re ...
分类:
其他好文 时间:
2021-05-23 23:46:05
阅读次数:
0
JavaScript垃圾回收机制 JavaScript使用垃圾自动回收机制进行内存管理,无需程序员手动分配和释放内存。垃圾回收的基本思路是确定哪些变量不会再次被使用,然后回收这些变量占用的内存。垃圾回收机制会影响应用程序的性能,因此它应该是周期性的,垃圾回收程序每隔一段时间会运行一次。常用的垃圾回收 ...
分类:
编程语言 时间:
2021-05-23 23:28:32
阅读次数:
0
在未做任何设置的前提下mint20安装不上向日葵,一直提示如下 设置并安装 sudo mv /etc/os-release{,.bak}sudo mv /etc/issue{,.bak}sudo mv /etc/upstream-release/ /etc/upsudo vim /etc/os-re ...
分类:
其他好文 时间:
2021-05-04 15:52:05
阅读次数:
0
Redis的主从复制模式下,一旦主节点由于故障不能提供服务,需要人工将从节点晋升为主节点,同时还要通知应用方更新主节点地址,对于很多应用场景这种故障处理的方式是无法接受的。可喜的是Redis从 2.8开始正式提供了 Redis Sentinel (哨兵)架构来解决这个问题。 1.基本概念 由于对Re ...
分类:
其他好文 时间:
2021-05-04 15:22:14
阅读次数:
0
2021-05-01,9点51 自己写测试debug redis代码:错误:/usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../lib64/crt1.o: In function `_start':(.text+0x20): undefined re ...
分类:
其他好文 时间:
2021-05-03 12:30:41
阅读次数:
0
In this lesson we're diving a bit deeper and learn how to inject services into Formly Extensions with the example of using ngx-translate to localize a ...
分类:
其他好文 时间:
2021-04-30 12:28:57
阅读次数:
0
直接上代码: public class TaskUtil { /** * 多次尝试执行任务,直到成功或次数用完 * @param task 任务 * @param times 循环次数 * @param millisecond 两个任务之间休眠时间(单位:毫秒) * @param <T> * @re ...
分类:
编程语言 时间:
2021-04-30 12:22:56
阅读次数:
0