来创造一个匿名提问箱吧

来创造一个匿名提问箱吧

私有部署提问盒

这两年提问盒形式的匿名问答越来越多了,像在朋友圈流行的 Popi,在推特流行的那个匿名提问箱,还有以前 QQ 的悄悄话。玩这类匿名社交最有意思的事情就是猜测提问者是谁,提问者提问时的心态。读者在看提问盒的回答历史的时候可以快速建立回答者的初步形象,然后进一步推断作者是一个什么样的人。

匿名?

阅读更多
阿里云Ai训练营DayThree
阿里云Ai训练营DayTwo
阿里云Ai训练营DayOne

阿里云Ai训练营DayOne

视觉生产

生产是输入输出的过程

  1. 给予一定的生产素材
  2. 然后通过视觉生产基础框架对素材,需求进行一定的语义分析理解
  3. 再经过视觉生产模型产出对应的产品。
阅读更多
Hexo静态网站多线部署

Hexo静态网站多线部署

多线部署:将同一个域名解析到多个服务器,并让不同地区的用户访问不同地区的服务器,以获得最好的访问体验

​ Hexo是静态网站,因此只需要服务器能够发送静态网页就足够了,国内的选择是coding pages或者是gitee pages但是后者码云的免费版并不能提供自定义域名服务,所以不予考虑。国外的可以选择 GitHub Pages

​ 🆗,首先你需要一个域名,然后在你的域名服务供应商那里做如下设置。

阅读更多
昼夜双版Typecho主题SplityRemake-新世界的灰烬
算法分析入门系列(三) 动态规划算法

算法分析入门系列(三) 动态规划算法

作业排程问题

问题描述

Automobile factory with two assembly lines(汽车厂两条装配线)

– Each line has n stations: S1,1, . . . , S1,n and S2,1, . . . , S2,n(每条装

配线有n个工序站台)

– Corresponding stations S1, j and S2, j perform the same function

but can take different amounts of time a1, j and a2, j (每条装配线的

第j个站台的功能相同,但是效率不一致)

– Entry times e1 and e2 and exit times x1 and x2(上线和下线时间)

阅读更多
算法分析入门系列(四) 最短路径算法
算法分析入门系列(二) 分治算法
算法分析入门系列(一) 排序算法

算法分析入门系列(一) 排序算法

排序算法

main函数代码

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
public static void main(String[] args) {
int max = 10;
System.out.println("插入排序-------------------------------------");
int[] num = randomCreate(max);
printResult(num);
Long bt = System.nanoTime();
int[] temp1 = insertSort(num);
Long et = System.nanoTime();
System.out.println("排序用时:" + (et - bt + ""));
printResult(temp1);


System.out.println("合并排序-------------------------------------");
int[] temp4 = randomCreate(max);
printResult(temp4);
Long bt2 = System.nanoTime();
mergeSort(temp4);
Long et2 = System.nanoTime();
System.out.println("排序用时:" + (et2 - bt2 + ""));
printResult(temp4);


System.out.println("快速排序-------------------------------------");
int[] temp5 = randomCreate(max);
printResult(temp5);
Long bt3 = System.nanoTime();
quickSort(temp5, 0, temp5.length - 1, false);
Long et3 = System.nanoTime();
System.out.println("排序用时:" + (et3 - bt3 + ""));
printResult(temp5);

System.out.println("随机化快速排序--------------------------------");
int[] temp9 = randomCreate(max);
printResult(temp9);
Long bt7 = System.nanoTime();
quickSort(temp9, 0, temp9.length - 1, true);
Long et7 = System.nanoTime();
System.out.println("排序用时:" + (et2 - bt2 + ""));
printResult(temp9);


System.out.println("桶排序---------------------------------------");
int[] temp6 = randomCreate(max);
printResult(temp6);
Long bt4 = System.nanoTime();
temp6 = bucketSort(temp6, max);
Long et4 = System.nanoTime();
System.out.println("排序用时:" + (et4 - bt4 + ""));
printResult(temp6);

System.out.println("计数排序-------------------------------------");
int[] temp7 = randomCreate(max);
printResult(temp7);
Long bt5 = System.nanoTime();
temp7 = countSort(temp7);
Long et5 = System.nanoTime();
System.out.println("排序用时:" + (et5 - bt5 + ""));
printResult(temp7);

System.out.println("基数排序-------------------------------------");
int[] temp8 = randomCreate(max);
printResult(temp8);
Long bt6 = System.nanoTime();
radixSort(temp8, (max + "").length());
Long et6 = System.nanoTime();
System.out.println("排序用时:" + (et6 - bt6 + ""));
printResult(temp8);
System.out.println("---------------------------------------------");

}
阅读更多