码迷,mamicode.com
首页 >  
搜索关键字:choose the best rout    ( 3445个结果
bzoj3162独钓寒江雪
题意 $n$阶树,求本质不同的独立集个数 做法 重新编号后重心是不变的,如果有两个重心,可以加个虚点 用树哈希判子树有多少个相同的子树,设某种有$k$个,如果原本方案数为$x$个 则方案数相当于解非负方程,为${x+k 1\choose k}$ ...
分类:其他好文   时间:2020-02-20 09:53:51    阅读次数:38
LeetCode | 0121. Best Time to Buy and Sell Stock买卖股票的最佳时机【Python】
LeetCode 0121. Best Time to Buy and Sell Stock买卖股票的最佳时机【Easy】【Python】【贪心】 Problem "LeetCode" Say you have an array for which the i th element is the p ...
分类:编程语言   时间:2020-02-19 23:55:42    阅读次数:125
a brief introduction of deep learning
three steps for deep learning Step1:神经网络(Neural network) Step2:模型评估(Goodness of function) Step3:选择最优函数(Pick best function) neural network 手动连接神经元 如: 1 ...
分类:其他好文   时间:2020-02-19 20:39:14    阅读次数:77
$O(m^3log(n))$求斐波那契数列
$O(m^3log(n))$求斐波那契数列 利用这个递推式:${F_{n+2}\choose F_{n+1}}={{1 1}\choose{1 0}}{F_{n+1}\choose{F_{n}}}$ 记${{1 1}\choose{1 0}}$为$A$ 得到${F_{n+1}\choose{F_{n ...
分类:其他好文   时间:2020-02-19 10:18:43    阅读次数:59
Leetocode全部5道买卖股票问题总结(121+122+123+188+309)
题目1 121. 买卖股票的最佳时机I: 链接:https://leetcode-cn.com/problems/best-time-to-buy-and-sell-stock/ 给定一个数组,它的第 i 个元素是一支给定股票第 i 天的价格。 如果你最多只允许完成一笔交易(即买入和卖出一支股票), ...
分类:其他好文   时间:2020-02-19 05:45:29    阅读次数:89
123买卖股票的最佳时机III
题目:给定一个数组,它的第 i 个元素是一支给定的股票在第 i 天的价格。设计一个算法来计算你所能获取的最大利润。你最多可以完成 两笔 交易。注意: 你不能同时参与多笔交易(你必须在再次购买前出售掉之前的股票)。链接:https://leetcode-cn.com/problems/best-tim ...
分类:其他好文   时间:2020-02-18 20:50:03    阅读次数:69
[Contract] Truffle 使用流程
Installation $ npm install -g truffle Choose ethereum client (Ganache OR truffle build in `truffle develop`) https://www.trufflesuite.com/docs/truffle ...
分类:其他好文   时间:2020-02-18 14:43:23    阅读次数:86
mybatis使用<choose> <when> 和 <if></if>
<select id = "" resultMap = ""> select * from table <where> <if test="type == 'x1' "> and 条件1; </if> <if test="type == 'x2' "> and 条件2; </if> </where> ...
分类:其他好文   时间:2020-02-14 10:48:56    阅读次数:244
HDU 2049
"HDU 2049" 思路 从$n$ 个人中选出$m$个人进行错排,即${n \choose m}$, "递推求组合数" $m$个人的 "错排公式" $f[m]=(m 1)(f[m 1]+f[m 2])$ 答案:${n \choose m}f[m]$ ...
分类:其他好文   时间:2020-02-13 14:58:36    阅读次数:52
PAT T1017 The Best Peak Shape
动态规划找最长上升子序列,正反遍历一遍序列即可~ #include<bits/stdc++.h> using namespace std; const int maxn=10010; int N; int a[maxn]; int l[maxn]; int r[maxn]; int main () ...
分类:其他好文   时间:2020-02-13 13:12:33    阅读次数:76
3445条   上一页 1 ... 18 19 20 21 22 ... 345 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!