上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 40 下一页
摘要: cat:连接文件并显示 -n:显示行号 -E:显示换行符 tac:连接文件并从尾部开始显示 more:分屏显示 less:和man命令一样用法 head -n:显示前n行 tail -n:显示后n行 -f:查看文件尾部不退出,等待显示后续追加至此文件的新内容 cut:显示文本中的某些字段 格式:cu 阅读全文
posted @ 2020-06-06 11:31 AI_Engineer 阅读(138) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2020-06-06 11:28 AI_Engineer 阅读(161) 评论(0) 推荐(0)
摘要: 静态库的制作和使用 1. 建立如下几个文件夹和文件 include lib main.c src include文件夹下包含如下文件 func.h int sum(int a, int b); int sub(int a, int b); int mul(int a, int b); int div 阅读全文
posted @ 2020-06-04 21:13 AI_Engineer 阅读(421) 评论(0) 推荐(0)
摘要: MNIST入门 import tensorflow as tf from tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets("./mnistdata/", one_hot = 阅读全文
posted @ 2020-06-03 16:16 AI_Engineer 阅读(152) 评论(0) 推荐(0)
摘要: 简单函数 #!/bin/bash fun1() { echo "This is my first fun!" } fun1 带 return 的函数 #!/bin/bash fun1() { a=1 b=2 c=`expr $a + $b` return $c } fun1 echo $? 注意: 阅读全文
posted @ 2020-06-02 23:00 AI_Engineer 阅读(131) 评论(0) 推荐(0)
摘要: if else #!/bin/bash a=$1 b=$2 if [ $a == $b ] then echo "a 等于 b" elif [ $a -gt $b ] then echo "a 大于 b" else echo "a 小于 b" fi for 循环 #!/bin/bash for i 阅读全文
posted @ 2020-06-02 20:58 AI_Engineer 阅读(125) 评论(0) 推荐(0)
摘要: Shell 和其他编程语言一样,支持多种运算符,包括: 算数运算符 关系运算符 布尔运算符 字符串运算符 文件测试运算符 原生bash不支持简单的数学运算,但是可以通过其他命令来实现,例如 awk 和 expr,expr 最常用。 expr expr 是一款表达式计算工具,使用它能完成表达式的求值操 阅读全文
posted @ 2020-06-02 19:18 AI_Engineer 阅读(155) 评论(0) 推荐(0)
摘要: 实例 以下实例我们向脚本传递三个参数,并分别输出,其中 $0 为执行的文件名: #!/bin/bash echo "Shell 传递参数实例!"; echo "执行的文件名:$0"; echo "第一个参数为:$1"; echo "第二个参数为:$2"; echo "第三个参数为:$3"; 输出结果 阅读全文
posted @ 2020-06-02 19:00 AI_Engineer 阅读(136) 评论(0) 推荐(0)
摘要: 基本用法 定义变量 name="xumaomao" 使用变量 echo $name 只读变量 name="xumaomao" readonly name name="xmm" //错误,只读变量不能修改 删除变量 unset name //不能删除只读变量 变量类型 运行shell时,会同时存在三种 阅读全文
posted @ 2020-06-02 17:14 AI_Engineer 阅读(113) 评论(0) 推荐(0)
摘要: 仓库初始化 git init 设置本地仓库签名 git config user.name user_name git config user.email user_email 设置系统用户签名 git config --global user.name user_name git config -- 阅读全文
posted @ 2020-05-29 22:25 AI_Engineer 阅读(155) 评论(0) 推荐(0)
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 40 下一页