摘要: #include <stdio.h>void auto_static (void){ int autoVar = 1; static int staticVar = 1; printf ("automatic = %i, static = %i\n", autoVar, staticVar); ++ 阅读全文
posted @ 2020-03-01 14:47 Robin_Wang 阅读(463) 评论(0) 推荐(0) 编辑
摘要: //将一个正整数转换成其他基数的函数#include <stdio.h>int convertedNumber [64];long int numberToConvert;int base;int digit = 0; void getNumberAndBase (void){ printf ("请 阅读全文
posted @ 2020-03-01 14:10 Robin_Wang 阅读(259) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h> void sort (int ArrayName[], int n){ int i, j, temp; for (i = 0; i < n - 1; ++i) for (j = i + 1; j < n; ++j) if (ArrayName[i] > Arra 阅读全文
posted @ 2020-03-01 14:07 Robin_Wang 阅读(1000) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h>int minimum (int values[10]) { int minValue, i; minValue = values[0]; for (i = 1; i < 10; ++i) if (values[i] < minValue) minValue = 阅读全文
posted @ 2020-03-01 14:01 Robin_Wang 阅读(1094) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h>#define isPrime(year) ((year%4==0&&year%100!=0)||(year%400==0))struct date{ int year; int month; int day;};int main(void){ int dateD 阅读全文
posted @ 2020-02-29 21:32 Robin_Wang 阅读(1058) 评论(0) 推荐(0) 编辑
摘要: #!/bin/bash CONCURRENCY=8 TIME_START=`date` for ((idx = 0; idx < $CONCURRENCY; idx++)) do time echo "scale=5000; a(1)*4" | bc -l > /dev/null & done ec 阅读全文
posted @ 2020-02-29 21:27 Robin_Wang 阅读(353) 评论(0) 推荐(0) 编辑
摘要: 使用ssh登陆到esxi,可使用如下命令esxtop -b >> test.csv收集esxi的性能参数。 esxtop -b -d 2 -n 10 > test.csv (启用batch模式,收取的间隔时间是2秒,连续收取10次保存成test.csv) 阅读全文
posted @ 2020-02-29 21:24 Robin_Wang 阅读(245) 评论(0) 推荐(0) 编辑
摘要: Performance monitor log for 1 second interval time with 500MB circular log file.Logman.exe create counter Perf-1Second -f bincirc -max 500 -c "\Logica 阅读全文
posted @ 2020-02-29 21:22 Robin_Wang 阅读(153) 评论(0) 推荐(0) 编辑
摘要: # include <stdio.h>int main(void){ int n,t; t = 0; for (n = 1; n <= 200; n = n + 1) //n=1是初始表达式,n<=200是循环条件,n=n+1是循环表达式,也可以写为++n或n++,for表达式后面不需要分号负责会立 阅读全文
posted @ 2020-02-29 21:09 Robin_Wang 阅读(1656) 评论(0) 推荐(0) 编辑