摘要: SELECT USER();#单行注释(文字说明,不是有效的代码)#分号表示一行语句的结束/*这是多行注释*/#下面创建一个新用户demo_c@localhost,该用户可以在本地登录本机的mysql服务#INSERT:插入;VALUES:值INSERT INTO mysql.user(HOST,U 阅读全文
posted @ 2022-04-08 12:47 long2020 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-04-03 11:23 long2020 阅读(5) 评论(0) 推荐(0) 编辑
摘要: //冒泡排序int[] arr={24,69,80, 89,57,13}; int min=0; for (int i = 0; i < arr.length-1; i++) { for (int j = 0; j < arr.length-1-i ; j++) { if(arr[j]>arr[j+ 阅读全文
posted @ 2022-04-03 08:34 long2020 阅读(12) 评论(0) 推荐(0) 编辑
摘要: // 4.已知有个升序的数组,要求插入一个元素,该数组顺序依然是升序, // 比如:[10,12,45,90],添加23后,数组为[10,12,23,45,90] // 思路本质数组扩容+定位 // 1。我们先确定添加数应该插入到哪个索引2.然后扩容 // HomeworkO4.java int[] 阅读全文
posted @ 2022-04-03 08:32 long2020 阅读(60) 评论(0) 推荐(0) 编辑
摘要: 1、批量替换指定多个文件的文件内容 在指定目录/your/path里,查找包含old_string字符串的所有文件,并用new_string字符串替换old_string字符串。 sed -i "s/old_string/new_string/g" `grep old_string -rl /you 阅读全文
posted @ 2021-12-03 10:09 long2020 阅读(662) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2021-08-21 07:53 long2020 阅读(20) 评论(0) 推荐(0) 编辑
摘要: 准备环境:nginx-1:172.25.70.1(master),主机名为:hostname1nginx-2:172.25.70.2(backup),主机名为:hostname2 2、安装配置(1)master和backup均安装nginx 1、检查nginx是否安装 :rpm -qa|grep n 阅读全文
posted @ 2021-08-18 11:03 long2020 阅读(143) 评论(0) 推荐(0) 编辑
摘要: centos 7 yum安装失败(出现repodata/repomd.xml: [Errno 14] HTTP Error 404 - Not Found)的解决方法 出现具体的错误提示如下: “ http://mirrors.aliyun.com/non-supported/rhel/7/x86_ 阅读全文
posted @ 2021-05-07 08:19 long2020 阅读(836) 评论(0) 推荐(0) 编辑
摘要: urlpatterns = [ path('', views.dashboard, name="sales_dashboard"), path('stu_enrollment/', views.stu_enrollment, name="stu_enrollment"), re_path('enro 阅读全文
posted @ 2021-03-30 12:30 long2020 阅读(79) 评论(0) 推荐(0) 编辑
摘要: def strip_str(stripstr,text): ''' 给定的字符串去除特定的字符 :param stripstr: 要去除字段 :param text: 原文 :return: ''' new_str=None if stripstr in text: new_str=text.rep 阅读全文
posted @ 2021-03-25 19:53 long2020 阅读(216) 评论(0) 推荐(0) 编辑