上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 19 下一页
摘要: package main import ( "encoding/json" "fmt" "io/ioutil" "os" "strconv" "time" ) type ResponseStruct struct { Signs []Sign `json:"signs"` } type Sign s 阅读全文
posted @ 2021-07-05 09:04 东宫得臣 阅读(169) 评论(0) 推荐(0) 编辑
摘要: void f(vector<string>& v, int i, const char *p) { if(p == nullptr) return; if(i<0 || v.size()<=i) error("bad index."); string s = v[i]; if(s == p) { / 阅读全文
posted @ 2021-07-04 21:31 东宫得臣 阅读(66) 评论(0) 推荐(0) 编辑
摘要: #include <iostream> int main() { int v[] = {1, 2, 3, 4, 5}; for(auto& x:v) std::cout<<x<<" "; std::cout<<std::endl; return 0;} We use auto where we do 阅读全文
posted @ 2021-07-04 17:44 东宫得臣 阅读(126) 评论(0) 推荐(0) 编辑
摘要: 用函数原型,在声明和定义一个函数时,必须使用参数类型描述。这种描述就是“原型”。 调用函数时,编译器使用原型确保正确传递参数并且正确地处理返回值。如果调用函数时程序 员出错了,编译器就会捕获这个错误。在函数原型中,参数表包含了应当传递给函数的参数类型 和参数的标识符(对声明而言可以是任选的)。参数的 阅读全文
posted @ 2021-07-04 15:53 东宫得臣 阅读(488) 评论(0) 推荐(0) 编辑
摘要: package main import "fmt" func makeSet() *customSet { return &customSet{ container: make(map[string]struct{}), } } type customSet struct { container m 阅读全文
posted @ 2021-04-27 20:01 东宫得臣 阅读(70) 评论(0) 推荐(0) 编辑
摘要: package main import ( "fmt" "log" "os" "sync" "strings" "io/ioutil" "encoding/json" ) type demo struct { } type creStruct struct { Name string `json:" 阅读全文
posted @ 2021-03-31 08:58 东宫得臣 阅读(1303) 评论(0) 推荐(0) 编辑
摘要: package main import ( "fmt" "os" ) func main() { var s, sep string for i := 1; i < len(os.Args); i++ { s += sep + os.Args[i] sep = " " } fmt.Println(s 阅读全文
posted @ 2020-09-23 14:32 东宫得臣 阅读(309) 评论(0) 推荐(0) 编辑
摘要: #include <errno.h> #include <string.h> #include <stdio.h> #include <fcntl.h> int main() { int fd, ret; enum { LENGTH = 100 }; char buf[LENGTH]; fd = o 阅读全文
posted @ 2020-09-09 15:02 东宫得臣 阅读(413) 评论(0) 推荐(0) 编辑
摘要: int find_file_in_dir(const char *path, const char *file) { struct dirent *entry; int ret=1; DIR *dir; dir = opendir(path); errno = 0; while((entry = r 阅读全文
posted @ 2020-08-17 21:35 东宫得臣 阅读(141) 评论(0) 推荐(0) 编辑
摘要: #!/usr/bin/python3 import pandas as pd def main(): df_iport = pd.read_excel('./ip-port.xlsx', sheet_name=0) for i in range(df_iport['目标地址'].__len__()) 阅读全文
posted @ 2020-05-13 14:33 东宫得臣 阅读(331) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 19 下一页