shell函数库的理解: 个人理解,shell函数库实质为一个脚本,脚本内包含了多个函数(函数具有普遍适用性)。 shell函数库的调用: 通过 . /path/lib/file.lib 或者 source /path/lib/file.lib的方式加载,然后正常函数方式调用。 示例如下: 创建函数 ...
分类:
系统相关 时间:
2019-09-05 11:59:33
阅读次数:
121
Shell脚本源码如下: #!/bin/sh #根据进程名杀死进程 if [ $# -lt 1 ] then echo "缺少参数:procedure_name" exit 1 fi PROCESS=`ps -ef|grep $1|grep -v grep|grep -v PPID|awk '{ p ...
分类:
系统相关 时间:
2019-09-04 13:43:30
阅读次数:
97
Hadoop自带的例子中,有一个计算Pi值的例子。 这个程序的原理是这样的。假如有一个边长为1的正方形。以正方形的一个端点为圆心,以1为半径,画一个圆弧,于是在正方形内就有了一个直角扇形。在正方形里随机生成若干的点,则有些点是在扇形内,有些点是在扇形外。正方形的面积是1,扇形的面积是0.25*Pi。 ...
分类:
其他好文 时间:
2019-09-03 22:01:36
阅读次数:
82
考核内容函数书写格式read-pexit编辑文件输入为exit退出执行脚本
分类:
其他好文 时间:
2019-09-03 20:37:22
阅读次数:
98
原文地址:https://www.jianshu.com/p/b12fc379d171 1 、启动 在xx.jar同级目录下建立run.bat文件,在run.bat文件中编辑下列文本。 保存 >双击运行即可! 2、停止 在任务管理器中直接结束掉相应的进程即可windows7 中在,查看 - 选择列中 ...
分类:
编程语言 时间:
2019-09-03 09:51:34
阅读次数:
600
原题链接在这里:https://leetcode.com/problems/increasing-triplet-subsequence/ 题目: Given an unsorted array return whether an increasing subsequence of length 3 ...
分类:
其他好文 时间:
2019-09-03 09:13:53
阅读次数:
64
效果图如下: #!/bin/bash# while truedocat << EOF// \\\\| 用户登录系统 | | 1、创建用户 || 2、删除用户 || 3、锁定用户 || 4、解锁用户 || 5、查看用户 || 6、退出脚本 | EOF read -p "请输入你的操作选择:" num# ...
分类:
系统相关 时间:
2019-09-02 14:01:21
阅读次数:
283
LeetCode地址:https://leetcode.com/problems/single-number-ii/Problem:Given an array of integers, every element appears three times except for one. Find t... ...
分类:
其他好文 时间:
2019-09-02 12:01:13
阅读次数:
68
Mac: ld: library not found for -lgcc_s.10.4 Checking for cc... ld: library not found for -lgcc_s.10.4 clang: error: linker command failed with exit co ...
分类:
系统相关 时间:
2019-09-02 11:51:06
阅读次数:
158
mysql脚本内容如下: #!/bin/bash mysql -uroot -pmdap <<EOF use sbb; UPDATE param_config SET effect_param_value=ineffect_param_value WHERE ineffect_param_value ...
分类:
数据库 时间:
2019-09-02 11:47:32
阅读次数:
273