摘要:
//判断文件是否存在 存在返回 true 不存在返回false func checkFileIsExist(filename string) bool { var exist = true if _, err := os.Stat(filename); os.IsNotExist(err) { ex 阅读全文
posted @ 2021-12-02 17:46
醒日是归时
阅读(466)
评论(0)
推荐(0)
摘要:
// path package main import ( "fmt" "os" "path" "path/filepath" ) func main() { //Path操作 fmt.Println("Path操作 ") fmt.Println(path.Base("http://www.baid 阅读全文
posted @ 2021-12-02 17:40
醒日是归时
阅读(179)
评论(0)
推荐(0)
摘要:
package main import "bytes" import "fmt" import "regexp" func main() { //这个测试一个字符串是否符合一个表达式。 match, _ := regexp.MatchString("p([a-z]+)ch", "peach") fm 阅读全文
posted @ 2021-12-02 14:21
醒日是归时
阅读(219)
评论(0)
推荐(0)