04 2019 档案

U3
摘要:一个项目里面可以有多个Activity 阅读全文

posted @ 2019-04-30 21:05 cltt 阅读(276) 评论(0) 推荐(0) 编辑

2018 ccpc final I. Cockroaches
摘要:I. Cockroaches time limit per test6.0 s memory limit per test256 MB inputstandard input outputstandard output There are N cockroaches in the field. Cockroach i is located at coordinate (xi,yi). No tw... 阅读全文

posted @ 2019-04-21 21:46 cltt 阅读(592) 评论(0) 推荐(0) 编辑

ccpc 2018 final G - Pastoral Life in Stardew Valley
摘要:#include #include #include #include using namespace std; #define ll long long const int N =100009; const ll mod = 1000000007; ll c[N][10]; void init() { c[0][0] =1ll; for... 阅读全文

posted @ 2019-04-19 22:00 cltt 阅读(389) 评论(0) 推荐(0) 编辑

2019年第十届蓝桥杯C/C++程序设计本科B组省赛 E迷宫
摘要:试题 E: 迷宫 本题总分:15 分 【问题描述】 下图给出了一个迷宫的平面图,其中标记为 1 的为障碍,标记为 0 的为可 以通行的地方。 010000 000100 001001 110000 迷宫的入口为左上角,出口为右下角,在迷宫中,只能从一个位置走到这 个它的上、下、左、右四个方向之一。 对于上面的迷宫,从入口开始,可以按DRRURRDDDR 的顺序通过迷宫, 一共 10 步。其中 D... 阅读全文

posted @ 2019-04-19 20:49 cltt 阅读(316) 评论(0) 推荐(0) 编辑

CERC2017 Gambling Guide,最短路变形,期望dp
摘要:分析 阅读全文

posted @ 2019-04-17 21:18 cltt 阅读(139) 评论(0) 推荐(0) 编辑

SGU 495
摘要:1 #include 2 using namespace std; 3 #define ll long long 4 const ll inf = 1000000000000; 5 const int N =100010; 6 int n,m; 7 double dp[N]; 8 /* 9 有N个礼物,M次选择,每次取的可能是未被选到的礼物 10 (礼物取走把空盒子放回可... 阅读全文

posted @ 2019-04-11 22:32 cltt 阅读(110) 评论(0) 推荐(0) 编辑

随机函数
摘要:#include using namespace std; int main() { srand((unsigned)time(NULL)); //产生的随机数范围是0~65536, for(int i = 0; i < 10;i++ ) cout << rand() << '\n'; cout << endl; ... 阅读全文

posted @ 2019-04-09 21:40 cltt 阅读(440) 评论(0) 推荐(0) 编辑

UVA - 12230
摘要:1 #include 2 using namespace std; 3 int n; 4 double d; 5 double p,l,v,ret,sum; 6 int cnt =1; 7 /* 8 9 村庄A,B之间有若干条河流,每条河流上的船速各自保持不变。告诉河流条数,两个村庄之间的距离 10 以及每条河流的距离A村庄的位置,宽度,船的速度。求A... 阅读全文

posted @ 2019-04-09 15:43 cltt 阅读(87) 评论(0) 推荐(0) 编辑

spoj1026 favorite dice
摘要:1 #include 2 using namespace std; 3 int n,t; 4 const int N = 1200; 5 double dp[N]; 6 /* 7 甩一个n面的骰子,问每一面都被甩到的需要甩的次数期望是多少。 8 dp[i]:已经甩到i个面了,要达到n个面还需要次数的期望 9 显然dp[n] = 0 10 那么逆序分析:dp[i] :再甩一... 阅读全文

posted @ 2019-04-09 15:31 cltt 阅读(90) 评论(0) 推荐(0) 编辑

概率dp
摘要:一:Uva12230Crossing Rivers (数学期望)题目大意:有个人每天要去公司上班,每次会经过N条河,家和公司的距离为D,默认在陆地的速度为1,给出N条河的信息,包括起始坐标p,宽度L,以及船的速度v。船会往返在河的两岸,人到达河岸时,船的位置是随机的(往返中)。问说人达到公司所需要的 阅读全文

posted @ 2019-04-08 22:31 cltt 阅读(114) 评论(0) 推荐(0) 编辑

重载问题
摘要:#include <iostream> #include <cstdio> #include <cstring> #include <algorithm> #include <cmath> #include <map> #include <utility> #include <vector> #in 阅读全文

posted @ 2019-04-08 21:01 cltt 阅读(108) 评论(0) 推荐(0) 编辑

树上dfs+思维
摘要:1 #include 2 const int N=1000010; 3 int cnt,head[N],n; 4 int size[N],num[N]; 5 void init() 6 { 7 cnt = 0; 8 for(int i =0;i<N;i++) head[i]=-1; 9 } 10 struct Node{ 11 int... 阅读全文

posted @ 2019-04-08 00:00 cltt 阅读(115) 评论(0) 推荐(0) 编辑

CERC2017 F: Faulty Factorial 简单数论题
摘要:1 #include 2 using namespace std; 3 #define ll long long 4 const int N = 10000006; 5 ll n,p,r; 6 ll poww(ll a,ll b){ 7 ll ans =1ll; 8 while(b){ 9 if(b&1) ans =ans... 阅读全文

posted @ 2019-04-07 21:45 cltt 阅读(231) 评论(0) 推荐(0) 编辑

win10 解决“ 'g++' 不是内部或外部命令,也不是可运行的程序或批处理文件”的问题
摘要:https://www.jianshu.com/p/9bffbaf12bed 2. 安装MinGW 将MinGW安装在D:\mingw文件夹下(可自由选择,这里为之后添加环境变量作为范例) 安装好后选择需要下载的安装包,选择All packets->MinGW->MinGW Base System- 阅读全文

posted @ 2019-04-07 21:17 cltt 阅读(1399) 评论(0) 推荐(0) 编辑

L2-029 特立独行的幸福 (25 分)
摘要:L2-029 特立独行的幸福 (25 分) L2-029 特立独行的幸福 (25 分) L2-029 特立独行的幸福 (25 分) 对一个十进制数的各位数字做一次平方和,称作一次迭代。如果一个十进制数能通过若干次迭代得到 1,就称该数为幸福数。1 是一个幸福数。此外,例如 19 经过 1 次迭代得到 阅读全文

posted @ 2019-04-04 21:19 cltt 阅读(807) 评论(0) 推荐(0) 编辑

L2-032 彩虹瓶 (25 分)
摘要:L2-032 彩虹瓶 (25 分) L2-032 彩虹瓶 (25 分) L2-032 彩虹瓶 (25 分) 彩虹瓶的制作过程(并不)是这样的:先把一大批空瓶铺放在装填场地上,然后按照一定的顺序将每种颜色的小球均匀撒到这批瓶子里。 假设彩虹瓶里要按顺序装 N 种颜色的小球(不妨将顺序就编号为 1 到 阅读全文

posted @ 2019-04-04 19:40 cltt 阅读(276) 评论(0) 推荐(0) 编辑

字符串函数
摘要:#include using namespace std; const int N = 1010; int main(){ char str[256] = { 0 };//str的大小(256)一定要填的。 int data = 1024; /* //将data转换为字符串 sprintf(str,"%d",data); cout #includ... 阅读全文

posted @ 2019-04-04 16:14 cltt 阅读(120) 评论(0) 推荐(0) 编辑

字符串模拟
摘要:L1-064 估值一亿的AI核心代码 (20 分) L1-064 估值一亿的AI核心代码 (20 分) L1-064 估值一亿的AI核心代码 (20 分) 以上图片来自新浪微博。 本题要求你实现一个稍微更值钱一点的 AI 英文问答程序,规则是: 无论用户说什么,首先把对方说的话在一行中原样打印出来; 阅读全文

posted @ 2019-04-04 16:05 cltt 阅读(319) 评论(0) 推荐(0) 编辑

判断字符
摘要:判断字符变量c是否为字母或数字,若是则返回非零,否则返回零。 阅读全文

posted @ 2019-04-03 22:50 cltt 阅读(192) 评论(0) 推荐(0) 编辑

U2
摘要:我们可以发现这三个button并没有将整个屏幕占据,而是根据内容适配大小。 我们在button2里面添加一个属性 android:layout_weight="1" ,发现布局变成这样了: 我们发现这次屏幕被三个button占据了,而且第一个和第三个button还是保持与内容适配大小,而第二个but 阅读全文

posted @ 2019-04-03 12:32 cltt 阅读(377) 评论(0) 推荐(0) 编辑

安装完后重启黑屏
摘要:https://blog.csdn.net/weixin_38533896/article/details/81023690 博客里面有安装教程 阅读全文

posted @ 2019-04-03 10:51 cltt 阅读(171) 评论(0) 推荐(0) 编辑

U1
摘要:1 如果 activity_main.xml没有xml代码可以对图像右键 go to mxl同时可以在design 和 text 切换 阅读全文

posted @ 2019-04-03 10:49 cltt 阅读(369) 评论(0) 推荐(0) 编辑

无线鼠标没反应了
摘要:换个电池吧!!!! 阅读全文

posted @ 2019-04-01 20:29 cltt 阅读(89) 评论(0) 推荐(0) 编辑

< 2025年3月 >
23 24 25 26 27 28 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 1 2 3 4 5

导航

统计

点击右上角即可分享
微信分享提示