- 博客(101)
- 资源 (2)
- 问答 (1)
- 收藏
- 关注
原创 三国杀钓鱼自动化
最近三国杀移动版出了一款钓鱼游戏,发现市面上很多编程爱好者就此作出了研究。这里我也出于学习的爱好就市面上多数相关程序进行了研究。
2024-10-24 08:30:41 11331 33
原创 Unity-PDF分割器(iTextSharp)
Unity 分割PDF。使用iTextSharp进行操作。涉及StandaloneFileBrowser的使用。
2024-02-29 15:11:34 1446 1
原创 Python-pyecharts生成精确到市的地图
pyecharts生成精确到市的地图。这里统一设置值为100,可以简单的实现点亮去过的城市这一功能。
2023-10-24 23:33:38 529
原创 Python BP算法模板
BP算法 (Back Propagation Algorithm) 的示例,其中包含神经网络聚类,比较大小的Python 代码示例。包含对每一段代码的粗略说明。
2023-05-14 20:26:18 532 1
原创 The 2022 ICPC Asia Regionals Online Contest (II) A、B、E、F、G、J、L
The 2022 ICPC Asia Regionals Online Contest (II)Yet Another RemainderNon-decreasing ArrayAn Interesting SequenceInfinity TreeGood PermutationA Game about Increasing SequencesQuadruple
2022-10-03 18:07:50 1236
原创 The 2022 ICPC Asia Regionals Online Contest - A 01 Sequence
The 2022 ICPC Asia Regionals Online Contest(I)
2022-09-20 19:23:45 553
原创 鲁东大学-电磁场与电磁波-实验七、八
鲁东大学-电磁场与电磁波-实验七、八实验七 👈点我跳转实验八 👈点我跳转实验七有一说一,课本的代码写的真的要逼死强迫症!!!作者肯定不是一个合格的程序员,实锤了,我已经膈应的不行了解析法clear;clc;%解析法程序v0=100;a=2;b=1;[x,y]=meshgrid(0:0.01:a,0:0.01:b);v1=0;nnnn=200;p=0;if nnnn==1 nnn=1;else nnn=1:2:2*nnnn-1;endfor nnnn=1
2022-05-07 16:21:10 420
原创 VHDL-任意分频器(50%占空比)
前言去年寒假前我的一个亲戚问我如何做一个五分频的分频器。我想这还不简单,不就是个计数器吗,但是发现并没有那么简单,因为偶数分频器根据上升沿计数就可以了,但是奇数分频器也可以,但是没法做到50%占空比。今天课上老师完美的解决了这个问题。偶分频我们之前学习过计数器,偶分配无非就是个计数器嘛,用信号做中间变量要注意他是滞后变值,所以修改的时候要考虑清除。这点没什么好说的直接上代码。library ieee; use ieee.std_logic_1164.all;use ieee.std_logic
2022-04-21 21:20:50 7056
原创 VHDL 有限状态机(FSM) 代码示例
示例一 "10"检测器library ieee;use ieee.std_logic_1164.all;entity FSM is port(Din,CLK,Reset:in std_logic;Dout:out std_logic);end FSM;architecture behave of FSM is type state is(S0,S1,S2); signal currentstate: state:=S0; signal nextstate:state:=S0;begin
2022-03-24 22:36:56 2183
原创 2020 Jiangsu Collegiate Programming Contest-A.Array
Array题目描述Yukikaze received an array (a1,a2,⋯an)as a gift. She decided to play with it. The game consists of q turns. In each turn, she will perform some kind of operation (listed below) on all elements in a subarray of a.In this problem, we define tha
2022-01-29 01:55:36 685
原创 约瑟夫序列 线段树 O(nlogn)
约瑟夫序列我们目前最常见的几种约瑟夫求法是通过暴力模拟所执行的。就连python 的数组切片复杂度也远远达不到O(nlogn)如果情况足够糟糕,那么切片做法复杂度可以到达O(n^2)和暴力做法没什么区别。那么我们用线段树来统计个数的方法,来记录下标。这样可以快速的查询。Accepted Code//#include<unordered_map>#include<algorithm>#include<iostream>#include<string.h&
2022-01-09 17:32:29 419
原创 信息学一本通-小球
小球问题描述许多的小球一个一个的从一棵满二叉树上掉下来组成FBT(Full Binary Tree,满二叉树),每一时间,一个正在下降的球第一个访问的是非叶子节点。然后继续下降时,或者走右子树,或者走左子树,直到访问到叶子节点。决定球运动方向的是每个节点的布尔值。最初,所有的节点都是false,当访问到一个节点时,如果这个节点是false,则这个球把它变成true,然后从左子树走,继续它的旅程。如果节点是true,则球也会改变它为false,而接下来从右子树走。满二叉树的标记方法如下图:因为所有的节
2022-01-08 18:25:21 231
原创 2022LDU寒假训练-程序补丁
程序补丁问题描述一个程序总有个错误,公司经常发布补丁来修正这些错误,遗憾的是,每用一个补丁,在修正某些错误的时候,同时会加入某些错误,每个补丁都有一定运行时间。某公司发表了一个游戏,出现了n个错误B={b1,b2,b3,…,bn},于是该公司发布了m个补丁,每个补丁的应用都是有条件的(即哪些错误必须存在,哪些错误不能存在)。求最少需要多少时间可全部修正这些错误。输入输入文件第一行有两个正整数n和m,n表示错误总数,m表示补丁总数,1≤n≤20, 1≤m≤100。接下来m行给出了m个补丁的信
2022-01-08 18:04:27 583
原创 Palindromic Primes
Palindromic Primes Category in Jeopardy!问题描述Prime numbers are defined as follows: a number is prime if it is greater than 1 and is evenly divisible only by itself and 1. Note that by definition neither zero nor one is a prime number.A palindromic numbe
2022-01-08 17:37:21 286
原创 汇编 32位无符号加法计算器
汇编 32位无符号加法计算器data segment Num1L dw 0 Num1H dw 0 Num2L dw 0 Num2H dw 0 ANSL dw 0 ANSH dw 0 table db 30h,31h,32h,33h,34h,35h,36h,37h,38h,39h,41h,42h,43h,44h,45h,46h Num dw 0data endsstack segment stack dw 50 dup
2021-11-22 22:53:57 1384
原创 POJ-The Unique MST
The Unique MST题目描述Given a connected undirected graph, tell if its minimum spanning tree is unique.Definition 1 (Spanning Tree): Consider a connected, undirected graph G = (V, E). A spanning tree of G is a subgraph of G, say T = (V’, E’), with the follo
2021-11-06 01:23:00 155
原创 微型计算机原理与接口技术-实验三
实验三ASCII码打表通过查表的方法实现十六进制数转换为 ASCII 码。**XLAT : DS:[BX+AL]为地址,提取存储器中的一个字节再送入ALdata segment table db 30h,31h,32h,33h,34h,35h,36h,37h,38h,39h,41h,42h,43h,44h,45h,46h hex db 9Ah ascl db 0 asch db 0data endscode segmentmain proc far assume cs:code
2021-11-02 17:30:35 1431
原创 微型计算机原理与接口技术-实验二
实验二字符显示程序请编写一个循环结构的程序,通过使用02H号功能调用,依次在屏幕上显示26个英文字母的大写形式。mov dl,"A"mov dh,"a"mov ah,02H mov cx,26loop1: int 21H xchg dl,dh int 21H xchg dl,dh inc dl inc dhloop loop1字符转换显示程序由键盘输入一个字母的小写形式,将其变换为大写形式输出。通过这个小程序的编写,熟悉0
2021-11-02 11:40:00 1095 1
原创 微型计算机原理与接口技术-实验一
实验一拆字程序将指定地址单元中存放的一个字节的两位16进制数进行拆分,高、低两位数字分别存入另外两个单元。例如:单元4000H的内容为27H,将其高、低两位拆出后,分别存放到4002H和4001H中。编写程序,执行后,4001H的内容应为低位07H,4002H的内容应为高位02H。data segment num db 3 dup(0)data endscode segment assume cs:code,ds:databegin: mov ax,data
2021-11-01 22:53:00 3290
原创 汇编基础代码示例
字符串传递data segment src db "hello!"data endsextra segment new db 6 dup("0")extra endscode segment assume cs:code,ds:data,es:extra start: mov ax,data mov ds,ax mov ax,extra mov es,ax lea si,src lea di,new mov c
2021-11-01 10:16:18 5115
原创 赛氪-二进制
二进制题目描述你是一个算法爱好者,在努力学习计算机知识。你知道,计算机最优美的地方在于二进制,这一点你在状压加o里面深有体会,当然二进制用在co and o时的也非常巧妙,更不用T说nini游戏都能跟于xor扯上关系了,而今天你又遇到了一道二进制的题目,对于爱思考的你,决定一直要把这道二进制题给切掉。你遇到了很多十进制的数,对于这些数,它们都管理着它们对应的分层,比如数字8,它的二进制是1,则它管理着4(10),2(10),两个分段,当数字闯的在2,4区间上增加时,沬代表二进制(10)和(10)两层
2021-10-24 16:34:45 457 5
原创 赛氪-zeal
zeal题目描述Yassin 最近在量化投资方面很有兴趣。为了研究哪只股票是真正的牛股,他把历史 nn 天每一天成交量最大的股票代码写成了一排,并构建了一套属于自己的“理论体系”。成交量多说明人气好,人气好的肯定买的人多,赚钱就要靠人气! – Yassin但是知道的人太多,这个大家都去接盘,那就都成为韭菜了 – Makik基于这个理论,Yassin 想知道 [L, R] 区间中人气“比较”好的股票有哪些,具体而言,他会给定你 L, R, k,你则需要告诉他 [L, R] 中出现 k 次的股票有
2021-10-22 19:50:11 346
原创 SDOI2009-HH的项链
SDOI2009-HH的项链题目描述HH 有一串由各种漂亮的贝壳组成的项链。HH 相信不同的贝壳会带来好运,所以每次散步完后,他都会随意取出一段贝壳,思考它们所表达的含义。HH 不断地收集新的贝壳,因此,他的项链变得越来越长。有一天,他突然提出了一个问题:某一段贝壳中,包含了多少种不同的贝壳?这个问题很难回答…… 因为项链实在是太长了。于是,他只好求助睿智的你,来解决这个问题。输入一行一个正整数 n,表示项链长度。第二行 n 个正整数 a_i,表示项链中第 i 个贝壳的种类。第三行一个整
2021-10-19 00:16:05 242
原创 HDU-Tunnel Warfare
Tunnel Warfare题目描述During the War of Resistance Against Japan, tunnel warfare was carried out extensively in the vast areas of north China Plain. Generally speaking, villages connected by tunnels lay in a line. Except the two at the ends, every village w
2021-08-28 18:10:17 378
原创 POJ-Hotel
Hotel题目描述The cows are journeying north to Thunder Bay in Canada to gain cultural enrichment and enjoy a vacation on the sunny shores of Lake Superior. Bessie, ever the competent travel agent, has named the Bullmoose Hotel on famed Cumberland Street as t
2021-08-18 16:57:51 152
原创 HDU-Can you answer these queries?
Can you answer these queries?题目描述A lot of battleships of evil are arranged in a line before the battle. Our commander decides to use our secret weapon to eliminate the battleships. Each of the battleships can be marked a value of endurance. For every at
2021-08-06 18:06:04 131
原创 Matrix Problem
Matrix Problem题目描述A teacher gives his students a problem to test his students’ construction skills.The teacher has two 0/1 matrices A and B with n rows and m columns, where all the 1 of both matrices separately form a 4-connected block. 4-connected mea
2021-05-09 19:22:40 402 1
原创 Codeforce-K-beautiful Strings
K-beautiful Strings题目描述You are given a string s consisting of lowercase English letters and a number k. Let’s call a string consisting of lowercase English letters beautiful if the number of occurrences of each letter in that string is divisible by k. Y
2021-04-10 17:19:31 281
原创 Codeforce-Clear the String
Clear the StringYou are given a string s of length n consisting of lowercase Latin letters. You may apply some operations to this string: in one operation you can delete some contiguous substring of this string, if all letters in the substring you delete
2021-03-25 21:16:11 282
原创 UPC-All in the Family
浏览目录All in the Family题目描述输入输出测试数据Sample Input1Sample Output1Sample Input2Sample Output2题目大意思路解析代码All in the Family题目描述The scientists working at the Family Genetics Institute are tracing the spread of a hereditary disease through family trees. They have
2021-03-22 20:32:06 384
原创 牛客-A | B
A | B题目描述给定两个正整数a,x,统计满足以下条件的b的个数:1.1≤b≤x2. a∣b=a+b输入描述第一行给出一个 t, 1≤t≤105接下来 t 行每行一对正整数a,x,1≤a,x≤109输出描述输出 t 行,每行一个正整数Sample Input21 22 3Sample Output11思路首先对题意进行理解。首先将数字a展开二进制,这样a中会有很多的0,那么你尽可能的用一个数去填补这个0,使之成为1,且这个数不会大于x。很容易想到,当a二
2021-01-11 01:28:30 292
原创 Atcoder-Queen on Grid
世 上 没 有 绝 望 的 处 境 只 有 对 处 境 绝 望 的 人Atcoder-Queen on GridProblem StatementWe have a grid with H horizontal rows and W vertical columns of squares.Square (i,j), which is at the i-th row from the top and j-th column from the left, is wall if Sij is # and
2020-11-16 13:23:15 208
VHDL仿真 上升沿触发,在没有上升沿的时候被触发,波形异常
2022-03-27
TA创建的收藏夹 TA关注的收藏夹
TA关注的人