题目链接:https://www.51nod.com/onlineJudge/questionCode.html#!problemId=1043 题意:中文题诶~ 思路:数位dp 我们用dp[i][j]来存储长度为2*i且一半和为j的所有情况(包括前导0的情况),为了方便我们现在只讨论其一半的和的情 ...
分类:
其他好文 时间:
2017-01-20 23:36:10
阅读次数:
395
#include<iostream> #include<string> using namespace std; struct BigReal //高精度实数 { int len; //长度 int num[10000]; int point; //小数点位置 BigReal() { len=1; ...
分类:
其他好文 时间:
2017-01-20 23:30:07
阅读次数:
250
头文件 #include <Dbt.h> 关键代码: 在窗口消息处理函数中,响应WM_DEVICECHANGE消息。 ...
分类:
其他好文 时间:
2017-01-20 23:23:32
阅读次数:
147
procedure TMainForm.PageControl1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer) ; begin PageControl1.BeginDrag(Fal ...
分类:
移动开发 时间:
2017-01-20 23:17:40
阅读次数:
219
#include <iostream>//这种在几个数里面任意去几个连续的数求和就用两个循环套一下就可以了 using namespace std; int main() { int n, i, j, sum, cnt = 0; cin >> n; //经分析可知,其i的取值不可能大于n/2+1,那 ...
分类:
其他好文 时间:
2017-01-20 16:28:35
阅读次数:
229
概率,$dp$。 人是独立的,可以先分别计算出每个人在$m$题中做出$0$题、$1$题......$m$题的概率。这个dp推一下就可以算出来了。 设$dp[i][j][k]$表示第$i$个人在前$j$题中,做出$k$题的概率。$dp[i][j][k]=p[i][j]*dp[i][j-1][k-1]+ ...
分类:
其他好文 时间:
2017-01-20 12:55:53
阅读次数:
211
参考链接:http://www.nowamagic.net/librarys/veda/detail/1271 http://www.ruanyifeng.com/blog/2008/06/base64.html cookie.js 文件 测试案例: ...
分类:
Web程序 时间:
2017-01-20 12:55:03
阅读次数:
310
public class AddressService extends Service { public static final String tag = "AddressService"; private TelephonyManager mTM; private MyPhoneStateLis... ...
分类:
其他好文 时间:
2017-01-20 07:17:47
阅读次数:
190
1. 问题描述: 原始数据是以行为单位的, 每行固定长度931个字节, 汉字占2个字节, 按照字典描述,共有96个字典,只有第32个字典为中文地址, 所以需要单独处理. 由于项目设计保密,故删除敏感数据. 供实验的数据是测试数据. 在处理过程中,按照规定的字典长度截取字符串的时候,发现处理到汉字的时 ...
分类:
编程语言 时间:
2017-01-19 16:13:09
阅读次数:
243
#include <cstdio> void main(){ double length; double l[300]; l[1] = 1.0/2; int i; for (i = 2;; ++i) { l[i] = l[i-1] + 1.0/(i+1); if (l[i] >= 5.20) bre ...
分类:
其他好文 时间:
2017-01-19 03:58:08
阅读次数:
142