<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[Slay__的博客]]></title><description><![CDATA[]]></description><link>https://blog.csdn.net/Slay__</link><language>zh-cn</language><generator>https://blog.csdn.net/</generator><copyright><![CDATA[Copyright &copy; Slay__]]></copyright><item><title><![CDATA[echarts漏斗图鼠标移入时内部文字阴影/描边]]></title><link>https://blog.csdn.net/Slay__/article/details/125614601</link><guid>https://blog.csdn.net/Slay__/article/details/125614601</guid><author>Slay__</author><pubDate>Tue, 05 Jul 2022 10:31:55 +0800</pubDate><description><![CDATA[echarts去除高亮时文字默认描边]]></description><category></category></item><item><title><![CDATA[echarts折线图数据过多的展示 -标签倾斜+标签数修改]]></title><link>https://blog.csdn.net/Slay__/article/details/125536970</link><guid>https://blog.csdn.net/Slay__/article/details/125536970</guid><author>Slay__</author><pubDate>Thu, 30 Jun 2022 11:29:02 +0800</pubDate><description><![CDATA[echarts、折线图、数据量过多、间隔取标签、标签倾斜]]></description><category></category></item><item><title><![CDATA[vue前端下载文件（后端接口返回byte[]数组）]]></title><link>https://blog.csdn.net/Slay__/article/details/124541666</link><guid>https://blog.csdn.net/Slay__/article/details/124541666</guid><author>Slay__</author><pubDate>Mon, 02 May 2022 15:35:42 +0800</pubDate><description><![CDATA[需求解析
此需求开始的时候最大的误区是，因为后端生成byte数组比较容易，因此总想在后端将其转为Blob发送，过程中遇到很多问题。
后来发现，直接发送字节流即可，前端将其转化为Blob很容易。
下载接口编写
getFile(path) {
      let formData = new FormData();
      formData.append('path', path); // 用于后端下载文件的路径
      this.$axios
        .post('http://localho]]></description><category></category></item><item><title><![CDATA[JS输入输出（ACM模式]]></title><link>https://blog.csdn.net/Slay__/article/details/124076044</link><guid>https://blog.csdn.net/Slay__/article/details/124076044</guid><author>Slay__</author><pubDate>Mon, 11 Apr 2022 16:38:59 +0800</pubDate><description><![CDATA[JS输入输出（ACM模式输入一行输入一个int数字一行为一个一维数组输入为`1 2 3`的形式输入为`123`的形式输出（数组输出为输入类似的形式）数组输出为`1,2,3`数组输出为`1 2 3`数组输出为`123`
使用V8模式，主要使用readline()读取每一行。
本质上输入的都是字符串，需要转化为数字。
同时也要注意不同的输入方式需要不同的处理。
输入
注意输入和split后每个元素都是string，所以如果输入的是数字或者Number数组，需要转化数字。
一行输入一个int数字
用readlin]]></description><category></category></item><item><title><![CDATA[edge运行js文件，控制台查看结果]]></title><link>https://blog.csdn.net/Slay__/article/details/123739598</link><guid>https://blog.csdn.net/Slay__/article/details/123739598</guid><author>Slay__</author><pubDate>Fri, 25 Mar 2022 16:41:05 +0800</pubDate><description><![CDATA[任意界面右键，选择检查。
选择源代码下面的片段，英文的话选sources下面的最后一个。

然后新片段新建脚本代码片段。
CTRL+Enter运行代码，即可控制台查看运行结果。


]]></description><category></category></item><item><title><![CDATA[关闭对话框，el-upload清空file-list]]></title><link>https://blog.csdn.net/Slay__/article/details/123212561</link><guid>https://blog.csdn.net/Slay__/article/details/123212561</guid><author>Slay__</author><pubDate>Tue, 01 Mar 2022 18:41:49 +0800</pubDate><description><![CDATA[如上，每次点开新对话框，上次上传的文件还在，需要关闭对话框时清空。
清空file-list
el-upload绑定ref，通过此ref调用el-upload提供的this.$refs.xxx.clearFiles()清空。
关闭对话框调用事件
el-dialog绑定关闭事件@close：@close='closeDialog'，编写该方法实现。
代码
就看el-upload的ref和对话框的close事件。
&lt;el-upload
            class="upload-demo"
   .]]></description><category></category></item><item><title><![CDATA[npm ERR——undefined (reading ‘isServer‘)错误和unable to resolve dependency tree错误]]></title><link>https://blog.csdn.net/Slay__/article/details/123200276</link><guid>https://blog.csdn.net/Slay__/article/details/123200276</guid><author>Slay__</author><pubDate>Tue, 01 Mar 2022 10:41:47 +0800</pubDate><description><![CDATA[npm install的错误
npm ERR! Cannot read properties of undefined (reading ‘isServer’)错误解决
关闭VPN
npm ERR! ERESOLVE unable to resolve dependency tree错误
npm install --legacy-peer-deps

]]></description><category></category></item><item><title><![CDATA[leetcode记录 —— 组合+排序问题 —— 回溯+DFS+剪枝]]></title><link>https://blog.csdn.net/Slay__/article/details/123109104</link><guid>https://blog.csdn.net/Slay__/article/details/123109104</guid><author>Slay__</author><pubDate>Thu, 24 Feb 2022 12:51:56 +0800</pubDate><description><![CDATA[46.全排列
flag数组记录元素是否用过，然后dfs中将没用过的挨个加进去，继续DFS，后面移除本步加的。一个len控制返回，如果len等于数组长度证明所有排序完，返回。
77.组合
每次DFS缩小区间到当前元素后面的所有的，这样避免加入同样的元素，也避免出现排列看起来不同，组合其实一样的情况。len控制list中满足需要的个数退出。
47.全排列II —— 包含重复元素，不能出现相同序列
不能出现相同序列，与46区别是，同一层出现相同元素时，这整个子树都要剪掉，因为第一棵树已经有了。剪掉的方法是：对数组]]></description><category></category></item><item><title><![CDATA[leetcode记录-排序-215、347、451、75]]></title><link>https://blog.csdn.net/Slay__/article/details/122952685</link><guid>https://blog.csdn.net/Slay__/article/details/122952685</guid><author>Slay__</author><pubDate>Tue, 15 Feb 2022 22:53:14 +0800</pubDate><description><![CDATA[Leetcode排序相关问题215.数组中第K大元素思路代码347.前K个高频元素思路代码451.根据字符出现频率排序思路代码75.颜色分类思路代码技巧总结排序相关思路元素出现个数统计HashMapList相关（二维List，Integer的List转数组）map操作（键集合、按键排序、某键值+1）字符List转String（Character数组同理）
215.数组中第K大元素

思路
【最终位置】求数组中第K大元素，与排序相关，快排每次都能找到一个元素在排序好的数组中的最终位置（且左边的都比该数小，右边]]></description><category></category></item><item><title><![CDATA[JAVA后端根据两个条件查询获得List，给前端分页展示，且两个条件均可能为空的处理]]></title><link>https://blog.csdn.net/Slay__/article/details/122866650</link><guid>https://blog.csdn.net/Slay__/article/details/122866650</guid><author>Slay__</author><pubDate>Thu, 10 Feb 2022 18:20:07 +0800</pubDate><description><![CDATA[自己想的办法，比较麻烦。。
DAO中：
根据两个条件的四种情况（均不空、前空、后空、均空），写四组查List以及获取满足条件记录数的方法
//    根据页数和每页展示数查
    @Select("select * from damage_assess_result where warhead_id=#{warheadId} and target_id=#{targetId} limit #{start} , #{end}")
    public List&lt;DamageAssessResult&g]]></description><category></category></item><item><title><![CDATA[leetcode记录-680-验证回文字符串Ⅱ-双指针]]></title><link>https://blog.csdn.net/Slay__/article/details/122848928</link><guid>https://blog.csdn.net/Slay__/article/details/122848928</guid><author>Slay__</author><pubDate>Wed, 09 Feb 2022 20:16:42 +0800</pubDate><description><![CDATA[680.验证回文字符串Ⅱ

思路
因为最多删一个字符能否成为回文字符串，双指针从首尾开始朝中间步进，当l和r处的字符相同，同时步进；当不同时，如果字符串为满足题意的串，则其[l+1,r]或者[l,r-1]为回文串，这时判断要是满足这两个条件就返回true，否则不满足返回false。需要写一个判断回文串的函数。
代码
class Solution {
    public boolean validPalindrome(String s) {
        int l=0,r=s.length()-1;
 ]]></description><category></category></item><item><title><![CDATA[vue进入界面后设置某组件自动定时刷新，退出时清除定时器]]></title><link>https://blog.csdn.net/Slay__/article/details/122843240</link><guid>https://blog.csdn.net/Slay__/article/details/122843240</guid><author>Slay__</author><pubDate>Wed, 09 Feb 2022 15:40:58 +0800</pubDate><description><![CDATA[需求
界面渲染数学公式会存在bug，时间较长等情况下渲染公式出错，需要自动定时刷新页面公式，同时为了不占用过多资源，退出该界面要清除定时器。
实现
需要使用created()和destroyed()方法，在created方法中设置定时器，并给让定时器等于Data中设置的变量，在destroyed离开界面时调用的方法体内，根据这个变量清除指定定时器。（下文只包含主要代码）
&lt;span :key="key" style="font-size:20px"&gt;{{ text }}&lt;/span&gt;]]></description><category></category></item><item><title><![CDATA[Element-UI中table组件内容整体居中]]></title><link>https://blog.csdn.net/Slay__/article/details/122839320</link><guid>https://blog.csdn.net/Slay__/article/details/122839320</guid><author>Slay__</author><pubDate>Wed, 09 Feb 2022 12:15:18 +0800</pubDate><description><![CDATA[style属性加margin:auto：
在组件的中加入即可。]]></description><category></category></item><item><title><![CDATA[leetcode记录-34-在排序数组中查找元素出现的第一个和最后一个位置-二分经典]]></title><link>https://blog.csdn.net/Slay__/article/details/122831960</link><guid>https://blog.csdn.net/Slay__/article/details/122831960</guid><author>Slay__</author><pubDate>Tue, 08 Feb 2022 22:06:01 +0800</pubDate><description><![CDATA[34-在排序数组中查找元素出现的第一个和最后一个位置

思路
如果直接用二分法寻找区间比较困难，当找到target时又要向左又要向右不知道该如何处理 —— 问题转化为寻找target出现的第一个位置（左边界）和寻找target出现的最后一个位置（右边界）两个二分，在每次二分中，注意l和r的初始条件，while的条件，l和r如何变化（自己习惯左闭右闭的写法），在寻找左边界时，mid大于和小于的情况正常r=mid-1和l=mid+1，但是当找到target的下标index，需要看左边是否还有，所以要让r=mid]]></description><category></category></item><item><title><![CDATA[leetcode记录-69-x的平方根-二分]]></title><link>https://blog.csdn.net/Slay__/article/details/122830445</link><guid>https://blog.csdn.net/Slay__/article/details/122830445</guid><author>Slay__</author><pubDate>Tue, 08 Feb 2022 20:18:39 +0800</pubDate><description><![CDATA[69.x的平方根

思路

自己的（也正确）：0和1直接输出，其他的按1到x进行二分查找，如果mid的平方大于x证明要在左侧找，让r=mid；而当mid的平方等于x，即找到了；当mid平方小于x，可能找到也可能没找到，结合mid+1判断，如果mid+1的平方也小于x，在右侧找，l=mid，否则退出；最后mid即为输出值。
题解：二分查找0-x，如果当前mid平方大于x，在左侧找，r=mid-1；如果当前mid平方小于等于x，先让ans为mid，然后l=mid+1，最后输出ans。

代码

自己的：

cl]]></description><category></category></item><item><title><![CDATA[Java中数组与List的区别]]></title><link>https://blog.csdn.net/Slay__/article/details/122821418</link><guid>https://blog.csdn.net/Slay__/article/details/122821418</guid><author>Slay__</author><pubDate>Tue, 08 Feb 2022 13:42:04 +0800</pubDate><description><![CDATA[① 数组声明的时候要指定数组的大小，用基本类型。
② List接口是一个有序的 Collection，没有固定大小的限制。其声明时用基本类型需要用其引用类型（List&lt;E&gt; list = new ArrayList&lt;&gt;(); 这里的E指的是引用类型）



① 数组向某下标插入元素是修改当前下标的元素。
② List向某下标插入元素是插入到指定下标，此下标原来的元素和后面的元素均后移。


List删除元素，删除当前下标的元素，后面的前移。


List的方法：



Array..]]></description><category></category></item><item><title><![CDATA[List与ArrayList、Map与HashMap的区别]]></title><link>https://blog.csdn.net/Slay__/article/details/122820338</link><guid>https://blog.csdn.net/Slay__/article/details/122820338</guid><author>Slay__</author><pubDate>Tue, 08 Feb 2022 11:25:19 +0800</pubDate><description><![CDATA[List和Map是接口，ArrayList和HashMap是接口的实现类。
不能单独使用接口来保存数据，但是可以创建其实现类的对象，然后使用接口引用来保存对象。如：Map&lt;String, Integer&gt; map = new HashMap&lt;&gt;(); 和 List list = new ArrayList();。
接口引用拥有接口的所有属性和方法，不会拥有其实现类的独有的属性和方法。如果两者有相同的属性或方法，调用的是接口的属性和实现类的方法。
用List list = new A.]]></description><category></category></item><item><title><![CDATA[leetcode记录-340-至多包含 K 个不同字符的最长子串-双指针]]></title><link>https://blog.csdn.net/Slay__/article/details/122816450</link><guid>https://blog.csdn.net/Slay__/article/details/122816450</guid><author>Slay__</author><pubDate>Mon, 07 Feb 2022 23:54:20 +0800</pubDate><description><![CDATA[340.至多包含 K 个不同字符的最长子串

思路
寻找字符串满足某个条件的子串，考虑双指针+滑动窗口思想（右指针一直前进，当遇到某个条件成立/不成立，更新左指针，然后右指针接着前进）。首先左右指针从0开始，右指针步进，用hashmap存储俩指针区间内每个字符最新出现的下标，当hashmap中元素个数大于要求的k时，证明元素多了，上一个子串寻找结束，更新左指针开始下一个子串寻找（舍弃目前区间内最右下标最小的舍弃，以获取最大长度），直到到最后。
代码
public class T340 {
    publi]]></description><category></category></item><item><title><![CDATA[leetcode记录-524-通过删除字母匹配到字典里最长单词-双指针]]></title><link>https://blog.csdn.net/Slay__/article/details/122815657</link><guid>https://blog.csdn.net/Slay__/article/details/122815657</guid><author>Slay__</author><pubDate>Mon, 07 Feb 2022 22:23:11 +0800</pubDate><description><![CDATA[524.通过删除字母匹配到字典里最长单词

思路
理解题意是一大难点。。。对于list中的字符串，如果可以由s删除一些字符得到，那么这个字符串初步符合标准，把他和str（初始为空）的比较，如果其长度更长或者长度相等下字母序小，则更新str为当前字符串。
代码
class Solution {
    public String findLongestWord(String s, List&lt;String&gt; dictionary) {
        String str="";
        f]]></description><category></category></item><item><title><![CDATA[leetcode记录-633-平方数之和]]></title><link>https://blog.csdn.net/Slay__/article/details/122794450</link><guid>https://blog.csdn.net/Slay__/article/details/122794450</guid><author>Slay__</author><pubDate>Sat, 05 Feb 2022 23:14:13 +0800</pubDate><description><![CDATA[633.平方数之和

思路
如果存在两个数平方和等于c，这两个数一定小于根号c取整（设为a），因此左指针l取0（0莫忘），右指针r取a，若平方和小于c，l++，大于c，r++，等于c，返回true。
代码
class Solution {
    public boolean judgeSquareSum(int c) {
        long left = 0;
        long right = (long) Math.sqrt(c);
        while (left &lt;= ri]]></description><category></category></item></channel></rss>