PAT 甲级 1042 Shuffling Machine (20 分)(简单题)
摘要:1042 Shuffling Machine (20 分) 1042 Shuffling Machine (20 分) 1042 Shuffling Machine (20 分) Shuffling is a procedure used to randomize a deck of playing
阅读全文
posted @
2019-08-31 12:48
蔡军帅
阅读(339)
推荐(0) 编辑
PAT 甲级 1042 Shuffling Machine (20 分)(简单题)
摘要:1042 Shuffling Machine (20 分) Shuffling is a procedure used to randomize a deck of playing cards. Beca...
阅读全文
posted @
2019-08-31 12:48
蔡军帅
阅读(94)
推荐(0) 编辑
PAT 甲级 1041 Be Unique (20 分)(简单,一遍过)
摘要:1041 Be Unique (20 分) Being unique is so important to people on Mars that even their lottery is desi...
阅读全文
posted @
2019-08-31 11:15
蔡军帅
阅读(99)
推荐(0) 编辑
PAT 甲级 1041 Be Unique (20 分)(简单,一遍过)
摘要:1041 Be Unique (20 分) 1041 Be Unique (20 分) 1041 Be Unique (20 分) Being unique is so important to people on Mars that even their lottery is designed i
阅读全文
posted @
2019-08-31 11:15
蔡军帅
阅读(355)
推荐(0) 编辑
PAT 甲级 1040 Longest Symmetric String (25 分)(字符串最长对称字串,遍历)
摘要:1040 Longest Symmetric String (25 分) 1040 Longest Symmetric String (25 分) 1040 Longest Symmetric String (25 分) Given a string, you are supposed to out
阅读全文
posted @
2019-08-31 09:36
蔡军帅
阅读(319)
推荐(0) 编辑
PAT 甲级 1040 Longest Symmetric String (25 分)(字符串最长对称字串,遍历)
摘要:1040 Longest Symmetric String (25 分) Given a string, you are supposed to output the length of the long...
阅读全文
posted @
2019-08-31 09:36
蔡军帅
阅读(91)
推荐(0) 编辑
PAT 甲级 1039 Course List for Student (25 分)(字符串哈希,优先队列,没想到是哈希)*...
摘要:1039 Course List for Student (25 分) Zhejiang University has 40000 students and provides 2500 courses. ...
阅读全文
posted @
2019-08-30 17:38
蔡军帅
阅读(139)
推荐(0) 编辑
PAT 甲级 1039 Course List for Student (25 分)(字符串哈希,优先队列,没想到是哈希)*
摘要:1039 Course List for Student (25 分) 1039 Course List for Student (25 分) 1039 Course List for Student (25 分) Zhejiang University has 40000 students and
阅读全文
posted @
2019-08-30 17:38
蔡军帅
阅读(284)
推荐(0) 编辑
PAT 甲级 1038 Recover the Smallest Number (30 分)(思维题,贪心)
摘要:1038 Recover the Smallest Number (30 分) 1038 Recover the Smallest Number (30 分) 1038 Recover the Smallest Number (30 分) Given a collection of number s
阅读全文
posted @
2019-08-29 16:59
蔡军帅
阅读(385)
推荐(1) 编辑
PAT 甲级 1038 Recover the Smallest Number (30 分)(思维题,贪心)
摘要:1038 Recover the Smallest Number (30 分) Given a collection of number segments, you are supposed to rec...
阅读全文
posted @
2019-08-29 16:59
蔡军帅
阅读(141)
推荐(0) 编辑
PAT 甲级 1037 Magic Coupon (25 分) (较简单,贪心)
摘要:1037 Magic Coupon (25 分) The magic shop in Mars is offering some magic coupons. Each coupon has an int...
阅读全文
posted @
2019-08-29 16:16
蔡军帅
阅读(120)
推荐(0) 编辑
PAT 甲级 1037 Magic Coupon (25 分) (较简单,贪心)
摘要:1037 Magic Coupon (25 分) 1037 Magic Coupon (25 分) 1037 Magic Coupon (25 分) The magic shop in Mars is offering some magic coupons. Each coupon has an i
阅读全文
posted @
2019-08-29 16:16
蔡军帅
阅读(458)
推荐(0) 编辑
PAT 甲级 1036 Boys vs Girls (25 分)(简单题)
摘要:1036 Boys vs Girls (25 分) 1036 Boys vs Girls (25 分) 1036 Boys vs Girls (25 分) This time you are asked to tell the difference between the lowest grade
阅读全文
posted @
2019-08-27 20:42
蔡军帅
阅读(349)
推荐(0) 编辑
PAT 甲级 1036 Boys vs Girls (25 分)(简单题)
摘要:1036 Boys vs Girls (25 分) This time you are asked to tell the difference between the lowest grade of a...
阅读全文
posted @
2019-08-27 20:42
蔡军帅
阅读(124)
推荐(0) 编辑
PAT 甲级 1035 Password (20 分)(简单题)
摘要:1035 Password (20 分) To prepare for PAT, the judge sometimes has to generate random passwords for the ...
阅读全文
posted @
2019-08-27 19:57
蔡军帅
阅读(121)
推荐(0) 编辑
PAT 甲级 1035 Password (20 分)(简单题)
摘要:1035 Password (20 分) 1035 Password (20 分) 1035 Password (20 分) To prepare for PAT, the judge sometimes has to generate random passwords for the users.
阅读全文
posted @
2019-08-27 19:57
蔡军帅
阅读(404)
推荐(0) 编辑
PAT 甲级 1034 Head of a Gang (30 分)(bfs,map,强连通)
摘要:1034 Head of a Gang (30 分) 1034 Head of a Gang (30 分) 1034 Head of a Gang (30 分) One way that the police finds the head of a gang is to check people's
阅读全文
posted @
2019-08-27 16:48
蔡军帅
阅读(466)
推荐(0) 编辑
PAT 甲级 1034 Head of a Gang (30 分)(bfs,map,强连通)
摘要:1034 Head of a Gang (30 分) One way that the police finds the head of ...
阅读全文
posted @
2019-08-27 16:48
蔡军帅
阅读(118)
推荐(0) 编辑
PAT 甲级 1033 To Fill or Not to Fill (25 分)(贪心,误以为动态规划,忽视了油量问题)*...
摘要:1033 To Fill or Not to Fill (25 分) With highways available, driving a car fro...
阅读全文
posted @
2019-08-26 19:41
蔡军帅
阅读(114)
推荐(0) 编辑
PAT 甲级 1033 To Fill or Not to Fill (25 分)(贪心,误以为动态规划,忽视了油量问题)*
摘要:1033 To Fill or Not to Fill (25 分) With highways available, driving a car from Hangzhou to any other city is easy. But since the tank capacity of a ca
阅读全文
posted @
2019-08-26 19:41
蔡军帅
阅读(1037)
推荐(0) 编辑
Python SciPy库——插值与拟合
摘要:插值与拟合 原文链接:https://zhuanlan.zhihu.com/p/28149195 1.最小二乘拟合 实例1 实例2 2.插值 实例1 实例2 B样条曲线插值一维数据的插值运算可以通过 interp1d()实现。其调用形式为:Interp1d可以计算x的取值范围之内任意点的函数值,并返
阅读全文
posted @
2019-08-24 15:35
蔡军帅
阅读(3307)
推荐(0) 编辑
Python SciPy库——插值与拟合
摘要:插值与拟合原文链接:https://zhuanlan.zhihu.com/p/28149195 1.最小二乘拟合实例1 # -*- coding: utf-8 -*-import numpy as npi...
阅读全文
posted @
2019-08-24 15:35
蔡军帅
阅读(224)
推荐(0) 编辑
matlab学习——05插值和拟合(黄河小浪底调水调沙问题)
摘要:05插值和拟合黄河小浪底调水调沙问题 data3.txt1800 1900 2100 2200 2300 2400 2500 2600 2650 2700 ...
阅读全文
posted @
2019-08-24 15:19
蔡军帅
阅读(257)
推荐(0) 编辑
matlab学习——05插值和拟合(黄河小浪底调水调沙问题)
摘要:05插值和拟合 黄河小浪底调水调沙问题 data3.txt 插值 拟合
阅读全文
posted @
2019-08-24 15:19
蔡军帅
阅读(3384)
推荐(0) 编辑
PAT 甲级 1032 Sharing (25 分)(结构体模拟链表,结构体的赋值是深拷贝)
摘要:1032 Sharing (25 分) 1032 Sharing (25 分) 1032 Sharing (25 分) To store English words, one method is to use linked lists and store a word letter by lette
阅读全文
posted @
2019-08-23 14:21
蔡军帅
阅读(378)
推荐(0) 编辑
PAT 甲级 1032 Sharing (25 分)(结构体模拟链表,结构体的赋值是深拷贝)
摘要:1032 Sharing (25 分)To store English words, one method i...
阅读全文
posted @
2019-08-23 14:21
蔡军帅
阅读(119)
推荐(0) 编辑
PAT 甲级 1031 Hello World for U (20 分)(一开始没看懂题意)
摘要:1031 Hello World for U (20 分) Given any string of N (≥) characters, you are...
阅读全文
posted @
2019-08-23 13:32
蔡军帅
阅读(118)
推荐(0) 编辑
PAT 甲级 1031 Hello World for U (20 分)(一开始没看懂题意)
摘要:1031 Hello World for U (20 分) 1031 Hello World for U (20 分) 1031 Hello World for U (20 分) Given any string of N (≥) characters, you are asked to form
阅读全文
posted @
2019-08-23 13:32
蔡军帅
阅读(378)
推荐(0) 编辑
matlab学习——05插值和拟合(一维二维插值,拟合)
摘要:05插值和拟合 1.一维插值 (1) 机床加工零件,试用分段线性和三次样条两种插值方法计算。并求x=0处的曲线斜率和13<=x<=15范围内y的最小值。 (2) 已知速度的四个观测值,用三次样条求位移S=0.15到0.18上的vd(t)积分 t 0.15 0.16 0.17 0.18vt 3.5 1
阅读全文
posted @
2019-08-22 19:05
蔡军帅
阅读(4460)
推荐(0) 编辑
matlab学习——05插值和拟合(一维二维插值,拟合)
摘要:05插值和拟合1.一维插值(1) 机床加工零件,试用分段线性和三次样条两种插值方法计算。并求x=0处的曲线斜率和13canshu = 0.0000 1.5483 ...
阅读全文
posted @
2019-08-22 19:05
蔡军帅
阅读(518)
推荐(0) 编辑
matlab学习——04图与网络(最短路,最小生成树,最大流)
摘要:04图与网络 1.最短路(1) 自己写的dijstra算法format compact;clc,clear alla=zeros(6);a(1,2)=50;a(1,4)=40;a(1,5)=25;a(1,...
阅读全文
posted @
2019-08-22 15:51
蔡军帅
阅读(354)
推荐(0) 编辑
matlab学习——04图与网络(最短路,最小生成树,最大流)
摘要:04图与网络 1.最短路 (1) 自己写的dijstra算法 (2) 输入邻接矩阵带包 (3) 输入节点和权重带包 2.最小生成树 xy = 0 5 16 20 33 23 35 25 10 15 20 24 20 25 11 7 0 3 d = 0 10 25 25 43 27 43 40 22
阅读全文
posted @
2019-08-22 15:51
蔡军帅
阅读(1114)
推荐(0) 编辑
matlab学习——02整数规划(蒙特卡洛法,指派问题,混合整数规划)
摘要:02整数规划 蒙特卡洛法(随机取样法) 编写文件mengte.m,目标函数f和约束向量g 主函数 指派问题 混合整数规划
阅读全文
posted @
2019-08-22 15:39
蔡军帅
阅读(1886)
推荐(0) 编辑
matlab学习——02整数规划(蒙特卡洛法,指派问题,混合整数规划)
摘要:02整数规划 蒙特卡洛法(随机取样法)编写文件mengte.m,目标函数f和约束向量gfunction[f,g]=mengte(x);f=x(1)^2+x(2)^2+3*x(3)^2+4*x(4)^2+2...
阅读全文
posted @
2019-08-22 15:39
蔡军帅
阅读(439)
推荐(0) 编辑
matlab学习——01线性规划
摘要:01线性规划format compact;% min fx% Ax=10% x1+3x2+x3=0f=[-2;3;5];a=[-2,5,1;1,3,1];b=[-10;12];aeq=[1,1,1];be...
阅读全文
posted @
2019-08-22 15:31
蔡军帅
阅读(210)
推荐(0) 编辑
MATLAB常用快捷键总结
摘要:MATLAB 命令栏显示处理的常用命令 清屏:clc 紧凑显示格式:format compact 宽松显示格式:format loose 数据高精度显示:format longG 数据低精度显示:format short 编辑器窗口(Editor)下的常用快捷键:自动对齐程序(整理缩进)-自动整理代
阅读全文
posted @
2019-08-21 17:38
蔡军帅
阅读(3989)
推荐(0) 编辑
MATLAB常用快捷键总结
摘要:MATLAB 命令栏显示处理的常用命令清屏:clc紧凑显示格式:format compact宽松显示格式:format loose数据高精度显示:format longG数据低精度显示:format sh...
阅读全文
posted @
2019-08-21 17:38
蔡军帅
阅读(782)
推荐(0) 编辑
Python动态展示遗传算法求解TSP旅行商问题()
摘要:版权声明:本文为博主原创文章,遵循 CC 4.0 by-sa 版权协议,转载请附上原文出处链接和本声明。本文链接:https://blog.csdn.net/jiang425776024/articl...
阅读全文
posted @
2019-08-21 16:25
蔡军帅
阅读(640)
推荐(0) 编辑
Python动态展示遗传算法求解TSP旅行商问题(转载)
摘要:版权声明:本文为博主原创文章,遵循 CC 4.0 by-sa 版权协议,转载请附上原文出处链接和本声明。本文链接:https://blog.csdn.net/jiang425776024/article/details/84532018 效果图:程序会动态的展示迭代过程,40以内城市大概迭代300次
阅读全文
posted @
2019-08-21 16:25
蔡军帅
阅读(8626)
推荐(1) 编辑
sklearn常见分类器(二分类模板)
摘要:# -*- coding: utf-8 -*- import pandas as pd import matplotlib matplotlib.rcParams['font.sans-serif']=[u'simHei'] matplotlib.rcParams['axes.unicode_minus']=False from sklearn.tree import DecisionTreeCl
阅读全文
posted @
2019-08-20 21:37
蔡军帅
阅读(6889)
推荐(3) 编辑
sklearn常见分类器(二分类模板)
摘要:# -*- coding: utf-8 -*-import pandas as pdimport matplotlibmatplotlib.rcParams['font.sans-serif']=[u's...
阅读全文
posted @
2019-08-20 21:37
蔡军帅
阅读(225)
推荐(0) 编辑
python图论包networks(最短路,最小生成树带包)
摘要:官方文档:https://networkx.github.io/documentation/networkx-1.10/reference/algorithms.html 最短路和最小生成树: impor...
阅读全文
posted @
2019-08-20 18:20
蔡军帅
阅读(260)
推荐(0) 编辑
python图论包networks(最短路,最小生成树带包)
摘要:官方文档: https://networkx.github.io/documentation/networkx-1.10/reference/algorithms.html 最短路和最小生成树:
阅读全文
posted @
2019-08-20 18:20
蔡军帅
阅读(4938)
推荐(2) 编辑
PAT 甲级 1030 Travel Plan (30 分)(dijstra,较简单,但要注意是从0到n-1)
摘要:1030 Travel Plan (30 分) 1030 Travel Plan (30 分) 1030 Travel Plan (30 分) A traveler's map gives the distances between cities along the highways, togeth
阅读全文
posted @
2019-08-19 21:00
蔡军帅
阅读(572)
推荐(0) 编辑
PAT 甲级 1030 Travel Plan (30 分)(dijstra,较简单,但要注意是从0到n-1)
摘要:1030 Travel Plan (30 分) A traveler's map gives the distances between c...
阅读全文
posted @
2019-08-19 21:00
蔡军帅
阅读(106)
推荐(0) 编辑
PAT 甲级 1029 Median (25 分)(思维题,找两个队列的中位数,没想到)*
摘要:1029 Median (25 分) Given an increasing sequence S of ...
阅读全文
posted @
2019-08-18 14:43
蔡军帅
阅读(90)
推荐(0) 编辑
PAT 甲级 1029 Median (25 分)(思维题,找两个队列的中位数,没想到)*
摘要:1029 Median (25 分) 1029 Median (25 分) 1029 Median (25 分) Given an increasing sequence S of N integers, the median is the number at the middle position
阅读全文
posted @
2019-08-18 14:43
蔡军帅
阅读(392)
推荐(0) 编辑
PAT 甲级 1028 List Sorting (25 分)(排序,简单题)
摘要:1028 List Sorting (25 分) 1028 List Sorting (25 分) 1028 List Sorting (25 分) Excel can sort records according to any column. Now you are supposed to imi
阅读全文
posted @
2019-08-18 13:59
蔡军帅
阅读(384)
推荐(0) 编辑
PAT 甲级 1028 List Sorting (25 分)(排序,简单题)
摘要:1028 List Sorting (25 分) Excel can sort records according to any...
阅读全文
posted @
2019-08-18 13:59
蔡军帅
阅读(98)
推荐(0) 编辑
PAT 甲级 1027 Colors in Mars (20 分)(简单,进制转换)
摘要:1027 Colors in Mars (20 分) People in Mars represent the colors...
阅读全文
posted @
2019-08-18 13:47
蔡军帅
阅读(102)
推荐(0) 编辑
PAT 甲级 1027 Colors in Mars (20 分)(简单,进制转换)
摘要:1027 Colors in Mars (20 分) 1027 Colors in Mars (20 分) 1027 Colors in Mars (20 分) People in Mars represent the colors in their computers in a similar w
阅读全文
posted @
2019-08-18 13:47
蔡军帅
阅读(175)
推荐(0) 编辑
PAT 甲级 1026 Table Tennis (30 分)(坑点很多,逻辑较复杂,做了1天)
摘要:1026 Table Tennis (30 分) A table tennis club has N tables available to the public. The tables are numbered from 1 to N. For any pair of players, if th
阅读全文
posted @
2019-08-18 13:31
蔡军帅
阅读(1068)
推荐(0) 编辑
PAT 甲级 1026 Table Tennis (30 分)(坑点很多,逻辑较复杂,做了1天)
摘要:1026 Table Tennis (30 分) A table tennis club has N tables available to the public. The tables are numb...
阅读全文
posted @
2019-08-18 13:31
蔡军帅
阅读(118)
推荐(0) 编辑
PAT 甲级1025 PAT Ranking (25 分)(结构体排序,第一次超时了,一次sort即可小技巧优化)...
摘要:题意:给定一次PAT测试的成绩,要求输出考生的编号,总排名,考场编号以及考场排名。分析: 题意很简单嘛,一开始上来就,一组组输入,一组组排序并记录组内排名,然后再来个总排序并算总排名,结果发现最后一...
阅读全文
posted @
2019-08-15 22:53
蔡军帅
阅读(128)
推荐(0) 编辑
PAT 甲级1025 PAT Ranking (25 分)(结构体排序,第一次超时了,一次sort即可小技巧优化)
摘要:题意: 给定一次PAT测试的成绩,要求输出考生的编号,总排名,考场编号以及考场排名。 分析: 题意很简单嘛,一开始上来就,一组组输入,一组组排序并记录组内排名,然后再来个总排序并算总排名,结果发现最后一个测试点超时。 发现自己一开始太傻太盲目,其实只要一次性全部输进来,记录好考场编号,一次排序就可以
阅读全文
posted @
2019-08-15 22:53
蔡军帅
阅读(470)
推荐(0) 编辑
PAT 甲级 1024 Palindromic Number (25 分)(大数加法,考虑这个数一开始是不是回文串)
摘要:1024 Palindromic Number (25 分) 1024 Palindromic Number (25 分) 1024 Palindromic Number (25 分) A number that will be the same when it is written forward
阅读全文
posted @
2019-08-15 22:08
蔡军帅
阅读(508)
推荐(0) 编辑
PAT 甲级 1024 Palindromic Number (25 分)(大数加法,考虑这个数一开始是不是回文串)...
摘要:1024 Palindromic Number (25 分) A number that will be the same when it is ...
阅读全文
posted @
2019-08-15 22:08
蔡军帅
阅读(135)
推荐(0) 编辑
PAT 甲级 1023 Have Fun with Numbers (20 分)(permutation是全排列题目没读懂)
摘要:1023 Have Fun with Numbers (20 分) Notice that the number 123456789 is a 9-digit number consisting exactly ...
阅读全文
posted @
2019-08-15 09:39
蔡军帅
阅读(118)
推荐(0) 编辑
PAT 甲级 1023 Have Fun with Numbers (20 分)(permutation是全排列题目没读懂)
摘要:1023 Have Fun with Numbers (20 分) 1023 Have Fun with Numbers (20 分) 1023 Have Fun with Numbers (20 分) 1023 Have Fun with Numbers (20 分) Notice that th
阅读全文
posted @
2019-08-15 09:39
蔡军帅
阅读(374)
推荐(0) 编辑
PAT 甲级 1022 Digital Library (30 分)(字符串读入getline,istringstream,测试点2时间坑点)
摘要:1022 Digital Library (30 分) 1022 Digital Library (30 分) 1022 Digital Library (30 分) A Digital Library contains millions of books, stored according to
阅读全文
posted @
2019-08-12 15:23
蔡军帅
阅读(434)
推荐(0) 编辑
PAT 甲级 1022 Digital Library (30 分)(字符串读入getline,istringstream,测试点2时间坑点)...
摘要:1022 Digital Library (30 分) A Digital Library contains millions of books, stored according to their titles...
阅读全文
posted @
2019-08-12 15:23
蔡军帅
阅读(139)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(六)——Autoencoder 自编码
摘要:import numpy as npnp.random.seed(1337)from keras.datasets import mnistfrom keras.models import Modelfrom k...
阅读全文
posted @
2019-08-11 22:38
蔡军帅
阅读(266)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(六)——Autoencoder 自编码
摘要:import numpy as np np.random.seed(1337) from keras.datasets import mnist from keras.models import Model from keras.layers import Dense, Input import matplotlib.pyplot as plt (x_train,y_train),(x...
阅读全文
posted @
2019-08-11 22:38
蔡军帅
阅读(1042)
推荐(0) 编辑
PAT 甲级 1021 Deepest Root (25 分)(bfs求树高,又可能存在part数part>2的情况)
摘要:1021 Deepest Root (25 分) 1021 Deepest Root (25 分) 1021 Deepest Root (25 分) A graph which is connected and acyclic can be considered a tree. The height
阅读全文
posted @
2019-08-11 19:28
蔡军帅
阅读(355)
推荐(0) 编辑
PAT 甲级 1021 Deepest Root (25 分)(bfs求树高,又可能存在part数part>2的情况)
摘要:1021 Deepest Root (25 分) A graph which is connected and acyclic can be considered a tree. The height of th...
阅读全文
posted @
2019-08-11 19:28
蔡军帅
阅读(85)
推荐(0) 编辑
PAT 甲级 1020 Tree Traversals (25 分)(二叉树已知后序和中序建树求层序)
摘要:1020 Tree Traversals (25 分) Suppose that all the keys in a binary tree are distinct positive integers. Giv...
阅读全文
posted @
2019-08-10 22:31
蔡军帅
阅读(96)
推荐(0) 编辑
PAT 甲级 1020 Tree Traversals (25 分)(二叉树已知后序和中序建树求层序)
摘要:1020 Tree Traversals (25 分) 1020 Tree Traversals (25 分) 1020 Tree Traversals (25 分) Suppose that all the keys in a binary tree are distinct positive i
阅读全文
posted @
2019-08-10 22:31
蔡军帅
阅读(185)
推荐(0) 编辑
PAT 甲级 1019 General Palindromic Number (进制转换,vector运用,一开始2个测试点没过)
摘要:1019 General Palindromic Number (20 分) 1019 General Palindromic Number (20 分) 1019 General Palindromic Number (20 分) A number that will be the same wh
阅读全文
posted @
2019-08-09 22:03
蔡军帅
阅读(389)
推荐(0) 编辑
PAT 甲级 1019 General Palindromic Number (进制转换,vector运用,一开始2个测试点没过)...
摘要:1019 General Palindromic Number (20 分) A number that will be the same when it is written forwards or backw...
阅读全文
posted @
2019-08-09 22:03
蔡军帅
阅读(117)
推荐(0) 编辑
PAT 甲级 1018 Public Bike Management (30 分)(dijstra+dfs,dfs记录路径,做了两天)
摘要:1018 Public Bike Management (30 分) There is a public bike service in Hangzhou City which provides great co...
阅读全文
posted @
2019-08-09 00:28
蔡军帅
阅读(114)
推荐(0) 编辑
PAT 甲级 1018 Public Bike Management (30 分)(dijstra+dfs,dfs记录路径,做了两天)
摘要:1018 Public Bike Management (30 分) 1018 Public Bike Management (30 分) 1018 Public Bike Management (30 分) There is a public bike service in Hangzhou Ci
阅读全文
posted @
2019-08-09 00:28
蔡军帅
阅读(618)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(五)——RNN LSTM Regressor 循环神经网络
摘要:# -*- coding: utf-8 -*- import numpy as np np.random.seed(1337) import matplotlib.pyplot as plt from keras.models import Sequential from keras.layers import LSTM,TimeDistributed,Dense from keras.opti...
阅读全文
posted @
2019-08-06 19:38
蔡军帅
阅读(1257)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(五)——RNN LSTM Regressor 循环神经网络
摘要:# -*- coding: utf-8 -*-import numpy as npnp.random.seed(1337)import matplotlib.pyplot as pltfrom keras.mod...
阅读全文
posted @
2019-08-06 19:38
蔡军帅
阅读(161)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(四)—— RNN Classifier 循环神经网络(手写数字图片识别)...
摘要:# -*- coding: utf-8 -*-import numpy as npnp.random.seed(1337)from keras.datasets import mnistfrom keras.ut...
阅读全文
posted @
2019-08-06 16:31
蔡军帅
阅读(181)
推荐(0) 编辑
用Keras搭建神经网络 简单模版(四)—— RNN Classifier 循环神经网络(手写数字图片识别)
摘要:# -*- coding: utf-8 -*- import numpy as np np.random.seed(1337) from keras.datasets import mnist from keras.utils import np_utils from keras.models import Sequential from keras.layers import SimpleR...
阅读全文
posted @
2019-08-06 16:31
蔡军帅
阅读(807)
推荐(0) 编辑
PAT 甲级 1017 Queueing at Bank (25 分)(模拟题,有点思维小技巧,第二次做才理清思路)
摘要:1017 Queueing at Bank (25 分) 1017 Queueing at Bank (25 分) 1017 Queueing at Bank (25 分) Suppose a bank has K windows open for service. There is a yello
阅读全文
posted @
2019-08-05 22:56
蔡军帅
阅读(726)
推荐(0) 编辑
PAT 甲级 1017 Queueing at Bank (25 分)(模拟题,有点思维小技巧,第二次做才理清思路)...
摘要:1017 Queueing at Bank (25 分) Suppose a bank has K windows open for service. There is a yellow line in fron...
阅读全文
posted @
2019-08-05 22:56
蔡军帅
阅读(100)
推荐(0) 编辑
PAT 甲级 1016 Phone Bills (25 分) (结构体排序,模拟题,巧妙算时间,坑点太多,debug了好久)...
摘要:1016 Phone Bills (25 分) A long-distance telephone company charges its customers by the following rules:Mak...
阅读全文
posted @
2019-08-04 00:34
蔡军帅
阅读(135)
推荐(0) 编辑
PAT 甲级 1016 Phone Bills (25 分) (结构体排序,模拟题,巧妙算时间,坑点太多,debug了好久)
摘要:1016 Phone Bills (25 分) 1016 Phone Bills (25 分) 1016 Phone Bills (25 分) A long-distance telephone company charges its customers by the following rules
阅读全文
posted @
2019-08-04 00:34
蔡军帅
阅读(1472)
推荐(1) 编辑
机器阅读理解综述Neural Machine Reading Comprehension Methods and Trends(略读笔记)
摘要:标题:Neural Machine Reading Comprehension: Methods and Trends 作者:Shanshan Liu, Xin Zhang, Sheng Zhang, Hui Wang, Weiming Zhang 链接:https://arxiv.org/pdf/
阅读全文
posted @
2019-08-03 14:58
蔡军帅
阅读(4275)
推荐(0) 编辑
机器阅读理解综述Neural Machine Reading Comprehension Methods and Trends(略读笔记)
摘要:标题:Neural Machine Reading Comprehension: Methods and Trends作者:Shanshan Liu, Xin Zhang, Sheng Zhang, Hui Wa...
阅读全文
posted @
2019-08-03 14:58
蔡军帅
阅读(128)
推荐(0) 编辑
PAT 甲级 1015 Reversible Primes (20 分) (进制转换和素数判断(错因为忘了=))
摘要:1015 Reversible Primes (20 分) A reversible prime in any number system is a prime whose "reverse" in that n...
阅读全文
posted @
2019-08-03 00:22
蔡军帅
阅读(130)
推荐(0) 编辑
PAT 甲级 1015 Reversible Primes (20 分) (进制转换和素数判断(错因为忘了=))
摘要:1015 Reversible Primes (20 分) 1015 Reversible Primes (20 分) 1015 Reversible Primes (20 分) A reversible prime in any number system is a prime whose "re
阅读全文
posted @
2019-08-03 00:22
蔡军帅
阅读(240)
推荐(0) 编辑
PTA中提交Python3程序的一些套路
摘要:0. FAQ 0.1 提交后提示“答案错误”或者“格式错误” PTA检查答案正确与否是通过字符串匹配实现的。所以可能有以下几种原因: 0.2 提交后提示"非零返回" 0.3 其他要注意的 PTA中的Python3无法正确处理中文字符,所以任何时候,提交的代码中都不要出现中文。新建题时不要在输入、输出
阅读全文
posted @
2019-08-03 00:19
蔡军帅
阅读(916)
推荐(0) 编辑
PTA中提交Python3程序的一些套路
摘要:0. FAQwhile True: raw = input() if raw == '': break print(sum(map(int, raw.split()))) 0.1 ...
阅读全文
posted @
2019-08-03 00:19
蔡军帅
阅读(235)
推荐(0) 编辑
PAT 甲级 1014 Waiting in Line (30 分)(queue的使用,模拟题,有个大坑)
摘要:1014 Waiting in Line (30 分) 1014 Waiting in Line (30 分) 1014 Waiting in Line (30 分) Suppose a bank has N windows open for service. There is a yellow l
阅读全文
posted @
2019-08-02 23:20
蔡军帅
阅读(709)
推荐(0) 编辑
PAT 甲级 1013 Battle Over Cities (25 分)(图的遍历,统计强连通分量个数,bfs,一遍就ac啦)
摘要:1013 Battle Over Cities (25 分) 1013 Battle Over Cities (25 分) 1013 Battle Over Cities (25 分) It is vitally important to have all the cities connected
阅读全文
posted @
2019-08-01 22:28
蔡军帅
阅读(368)
推荐(0) 编辑
PAT 甲级 1013 Battle Over Cities (25 分)(图的遍历,统计强连通分量个数,bfs,一遍就ac啦)...
摘要:1013 Battle Over Cities (25 分) It is vitally important to have all the cities connected by highways in a w...
阅读全文
posted @
2019-08-01 22:28
蔡军帅
阅读(89)
推荐(0) 编辑