(1)深度优先 1 #include <stdio.h> 2 int book[101],sum = 0,n,e[101][101]; 3 void dfs(int cur) 4 { 5 int i; 6 printf("%d",cur); 7 sum++; 8 if(sum == n) 9 { 1 ...
分类:
其他好文 时间:
2020-04-21 18:40:24
阅读次数:
46
Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have ex ...
分类:
其他好文 时间:
2020-04-21 18:36:52
阅读次数:
67
前言: (文末有福利) 今天给大家介绍一个新的ORM框架 JOOQ,可能很多朋友还没有听说过这个框架. 之前也是一直在使用Mybatis框架作为Java工程中的持久层访问框架,但是最近的一些项目采用JOOQ框架开发后,表示再也不想用Mybatis了! 为什么这么说呢?因为JOOQ在代码层面要比Myb ...
分类:
其他好文 时间:
2020-04-21 15:34:51
阅读次数:
71
题目描述 总时间限制: 15000ms 单个测试点时间限制: 5000ms 内存限制: 228000kB 描述 The SUM problem can be formulated as follows: given four lists A, B, C, D of integer values, c ...
分类:
其他好文 时间:
2020-04-21 15:23:40
阅读次数:
62
程序源码: program main implicit none integer i,sum real t(7),tmax tmax=0.0;sum=0 do i=1,7 read*,t(i) if(t(i)>=tmax) then tmax=t(i) end if if(t(i)>20) then ...
分类:
其他好文 时间:
2020-04-21 15:09:36
阅读次数:
44
机器学习基础:朴素贝叶斯小结 CONTENTS "1. 全概率公式与贝叶斯公式" "2. 朴素贝叶斯的模型" "3. 朴素贝叶斯的推断过程" "4. 朴素贝叶斯的参数估计" "5. 朴素贝叶斯算法优缺点" "6. 代码实践" 1. 全概率公式与贝叶斯公式 $$ 全概率公式: P(X)=\sum_{k ...
分类:
其他好文 时间:
2020-04-21 13:07:28
阅读次数:
66
"传送门" 题意: 求$\displaystyle \sum_{i=1}^n i^mm^i,n\leq 10^9,m\leq 1000$。 思路: $m$比较小,考虑从$m$入手进行递推: 设$f(j)=\sum_{i=1}^ni^jm^i$,则$mf(j)=\sum_{i=1}^ni^jm^{i+ ...
分类:
其他好文 时间:
2020-04-21 09:51:15
阅读次数:
72
Newtonsoft.Json与System.Text.Json区别 在 Newtonsoft.Json中可以使用例如 .AddJsonOptions(options => { options.SerializerSettings.DateFormatString = "yyyy-MM-dd HH: ...
分类:
Web程序 时间:
2020-04-21 09:30:50
阅读次数:
74
1. 使用for语句计算1~10的数字之和 2. 利用do while语句实现数字1~10的和 3. 用while语句实现数字1~10之和 应注意的是在循环中i++不能放在sum+=i前面,否则结果会出现错误,如图所示。 这是因为在i=10的时候sum=55,此时while(i<=10)正确,程序继 ...
分类:
其他好文 时间:
2020-04-21 09:26:33
阅读次数:
92
D - Sum of Large Numbers 题意:题目的大概意思就是存在N+1个数,分别为10100,10100+1,10100+2,10100+3.........10100+N。从中至少选出K个数,求选出的K个数的和总共有多少种。 题解:这一题是一个很好的思维题,你看,选择K数,和选择K+ ...
分类:
其他好文 时间:
2020-04-21 00:27:19
阅读次数:
134