原神升级计划数据表:重新布局,优化代码

news2024/11/25 12:22:09

<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>原神升级计划数据表</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            body {
                background: #0b1b2c;
            }
        }
        header {
            width: 100vw;
            height: 40px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background-color: #cbcbcb;
            /* logo */
            figure.logo {
                width: 262px;
                height: 50px;
                /* 缩小 */
                transform: scale(0.8);
                margin-top: 2px;
                margin-left: -15px;
                border-radius: 50%;
                background: #f30303;
                box-shadow: inset 4px 4px 4px rgba(255, 255, 255, 0.6),
                    inset -4px -4px 5px rgba(0, 0, 0, 0.6);
                z-index: 99;
                figcaption {
                    background: hsl(0, 0%, 0%);
                    background-clip: text;
                    -webkit-background-clip: text;
                    -webkit-text-fill-color: transparent;
                    font-weight: bold;
                    box-shadow: inset 4px 4px 4px rgba(255, 255, 255, 0.6), inset -4px -4px 5px rgba(0, 0, 0, 0.6);
                    letter-spacing: -3px;
                    line-height: 45px;
                    border-radius: 50%;
                    font-size: 40px;
                    width: 152px;
                }
                .my_name1 {
                    text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.726);
                    clip-path: polygon(0% 0%, 100% 0%, 100% 50%, 0% 50%);
                    transform: translate(35%, 0%);
                    -webkit-text-stroke: #fffbfb 1px;
                }
                .my_name2 {
                    text-shadow: 1px 1px 1px hsla(160, 100%, 37%, 0.555);
                    clip-path: polygon(0% 50%, 100% 50%, 100% 100%, 0% 100%);
                    transform: translate(35%, -93%);
                    -webkit-text-stroke: #ffffff 1px;
                }
                img {
                    width: 60px;
                    height: 35px;
                    border-radius: 50%;
                    transition: transform 0.3s ease;
                    position: absolute;
                    &:hover {
                        transform: scale(1.3);
                        filter: drop-shadow(0 0 0.3em #ff0202);
                    }
                }
                .kong {
                    margin-top: 7px;
                    margin-left: 200px;
                }
                .ying {
                    top: 7px;
                    margin-left: 2px;
                }
            }
            /* 时间 */
            time {
                background: -webkit-linear-gradient(315deg, #e1ff00 50%, #ff0000);
                background-clip: text;
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                font-size: 1.5rem;
                font-weight: 900;
                text-shadow: 2px -1px 8px rgba(250, 80, 193, 0.323);
                sub {
                    -webkit-text-fill-color: #cfd601;
                    text-shadow: 1px 1px 1px #100000;
                    font-size: 1rem;
                }
            }
            /* 全屏还原关闭按钮 */
            menu {
                display: flex;
                button {
                    background: none;
                    border: none;
                }
                img {
                    width: 35px;
                    margin-top: 5px;
                    margin-right: 5px;
                    cursor: pointer;
                    &:hover {
                        transform: scale(1.2);
                        padding: 5px;
                        background: #ffd000;
                    }
                }
                button:nth-child(2) {
                    display: none;
                    /* 放大镜效果 */
                    transform: scale(1.16);
                }
            }
        }
        main {
            display: flex;
            align-items: center;
            align-items: flex-start;
            #countdownContainer {
                display: flex;
                flex-direction: column;
                align-items: flex-end;
                button {
                    font-size: 1.5rem;
                    color: hsl(0, 0%, 100%);
                    text-shadow: 1px 1px 1px #100000;
                    cursor: pointer;
                    border-radius: 3px;
                    background-color: #67c23a;
                    border: none;
                    margin: 5px;
                    padding: 3px;
                }
                button:first-child {
                    margin-top: 35px;
                }
                dialog {
                    transform: translate(180%, 80%);
                    padding: 10px;
                    border: 1px solid #ddd;
                    border-radius: 5px;
                    background-color: #f3f3f3;
                }
                dialog::backdrop {
                    /* 模糊背景 */
                    backdrop-filter: blur(2px);
                }
            }
            #characterTableContainer {
                margin: 10px;
            }
            table {
                border-collapse: collapse;
                span {
                    color: #ffffff;
                    text-shadow: 1px 1px 1px #030303;
                }
                th,
                td {
                    text-align: center;
                    padding: 8px;
                    border: 1px solid #ddd;
                }
                th {
                    background-color: #9f9e9e;
                    /* -webkit-text-stroke:#fffbfb 1px; */
                }
                td {
                    color: hsl(0, 0%, 100%);
                    text-shadow: 1px 1px 1px #030303;
                }
                .editable {
                    cursor: pointer;
                    /* 改变鼠标样式为指针 */
                    transition: background-color 0.3s;
                    /* 添加过渡效果 */
                    &:hover {
                        background-color: #000000;
                        padding: 5px;
                        /* 确保悬停时的padding与正常状态一致 */
                        transition: background-color 0.3s ease, padding 0.3s ease;
                        /* 添加过渡效果,使变化更平滑 */
                    }
                }
            }
        }
        #dialogAddCharacter {
            transform: translate(120%, 10%);
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 5px;
            background-color: #f3f3f3;
        }
    </style>
</head>
<body>
    <header>
        <figure class="logo">
            <a href="https://blog.csdn.net/lulei5153?spm=1011.2415.3001.5343" title="与妖为邻CSDN博客" target="_blank">
                <img class="kong" src="file:///D:/img/icon.ico" alt="与妖为邻">
            </a>
            <figcaption class="my_name1">与妖为邻</figcaption>
            <figcaption class="my_name2">与妖为邻</figcaption>
            <a href="file:///D:/web/html%E9%A6%96%E9%A1%B5/%E5%A4%87%E5%BF%98%E5%BD%95.html" class="home_page"
                title="首页" target="_blank">
                <img class="ying" src="file:///D:/img/ying.png" alt="与妖为邻">
            </a>
        </figure>
        <time datetime="2024-07-10" title="2024-07-10" id="dateTime">2024-07-10</time>
        <iframe class="tianqi" frameborder="0" width="280" height="36" scrolling="no" hspace="0"
            src="https://i.tianqi.com/?c=code&id=99"></iframe>
        <menu>
            <button class="fullScreen" type="button"><img src="file:///D:/img/全屏.svg" alt="全屏"
                    onclick="fullScreen()"></button>
            <button class="exitFullScreen" type="button"><img src="file:///D:/img/还原.svg" alt="还原"
                    onclick="exitFullScreen()"></button>
            <button type="button"><img src="file:///D:/img/关闭.svg" alt="关闭" onclick="closeAll()"></button>
        </menu>
    </header>
    <main>
        <div id="countdownContainer"></div>
        <div id="characterTableContainer">
            <dialog id="dialogAddCharacter">
                <form id="addCharacterForm">
                    <label for="element">元素:</label>
                    <select id="element" name="element">
                        <option value="火">火</option>
                        <option value="水">水</option>
                        <option value="风">风</option>
                        <option value="雷">雷</option>
                        <option value="草">草</option>
                        <option value="冰">冰</option>
                        <option value="岩">岩</option>
                    </select>
                    <button type="submit" style="float: right;">关闭</button><br><br>
                    <label for="role">角色:</label>
                    <input type="text" id="role" name="role"><br><br>
                    <label for="level">等级:</label>
                    <input type="number" id="level" name="level"><br><br>
                    <label for="constellation">命座:</label>
                    <select id="constellation" name="constellation">
                        <option value="0">0</option>
                        <option value="1">1</option>
                        <option value="2">2</option>
                        <option value="3">3</option>
                        <option value="4">4</option>
                        <option value="5">5</option>
                        <option value="6">6</option>
                    </select><br><br>
                    <label for="talent">天赋:</label>
                    <input type="text" id="talent" name="talent"><br><br>
                    <label for="note">备注:</label>
                    <input type="text" id="note" name="note"><br><br>
                    <button type="button" onclick="addCharacter()"
                        style="display: block; margin: 5px auto;">添加角色</button><br>
                </form>
            </dialog>
            <table id="characterTable"></table>
        </div>
    </main>
    <script>
        const current_time = document.getElementById("dateTime");
        function showTime() {
            const now = new Date();
            const time = `${now.getFullYear()}-${("0" + (now.getMonth() + 1)).slice(-2)}-${("0" + now.getDate()).slice(-2)}<sub id='sub'>${["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"][now.getDay()]}</sub> ${("0" + now.getHours()).slice(-2)}:${("0" + now.getMinutes()).slice(-2)}:${("0" + now.getSeconds()).slice(-2)}`;
            current_time.innerHTML = time;
        }
        setInterval(showTime, 1000);
        function fullScreen() {
            const elem = document.documentElement;
            ['requestFullscreen', 'mozRequestFullScreen', 'webkitRequestFullscreen', 'msRequestFullscreen'].forEach(method => elem[method] && elem[method]());
        }
        function exitFullScreen() {
            ['exitFullscreen', 'mozCancelFullScreen', 'webkitExitFullscreen', 'msExitFullscreen'].forEach(method => document[method] && document[method]());
        }
        document.addEventListener("fullscreenchange", () => {
            document.fullscreenElement ? [fullScreenBtn.style.display = "none", exitFullScreenBtn.style.display = "block"] : [fullScreenBtn.style.display = "block", exitFullScreenBtn.style.display = "none"];
        });
        function closeAll() {
            window.close();
        }
        const countdownContainer = document.getElementById('countdownContainer');
        function createCountdownElement(id) {
            const button = document.createElement('button');
            button.textContent = `第${id}个倒计时`;
            button.id = `countdownElement${id}`;
            button.onclick = () => document.getElementById(`dialogCountdownElement${id}`).showModal();
            const dialog = document.createElement('dialog');
            dialog.id = `dialogCountdownElement${id}`;
            const form = document.createElement('form');
            form.method = 'dialog';
            const messageDiv = document.createElement('div');
            messageDiv.appendChild(document.createElement('label')).textContent = '更改提示信息:';
            messageDiv.appendChild(document.createElement('input')).type = 'text';
            messageDiv.lastChild.id = `message${id}`;
            messageDiv.lastChild.value = '距离2024年国庆节还有:';
            const targetDateDiv = document.createElement('div');
            targetDateDiv.appendChild(document.createElement('label')).textContent = '更改目标日期:';
            targetDateDiv.appendChild(document.createElement('input')).type = 'datetime-local';
            targetDateDiv.lastChild.id = `targetDate${id}`;
            form.appendChild(messageDiv);
            form.appendChild(targetDateDiv);
            form.appendChild(document.createElement('button')).type = 'submit';
            form.lastChild.textContent = '关闭';
            form.lastChild.style.display = 'block';
            form.lastChild.style.margin = '5px auto';
            dialog.appendChild(form);
            countdownContainer.appendChild(button);
            countdownContainer.appendChild(dialog);
        }
        for (let i = 1; i <= 4; i++) createCountdownElement(i);
        const countdownData = {
            1: { message: 'message1', targetDate: 'targetDate1' },
            2: { message: 'message2', targetDate: 'targetDate2' },
            3: { message: 'message3', targetDate: 'targetDate3' },
            4: { message: 'message4', targetDate: 'targetDate4' }
        };
        window.onload = () => Object.keys(countdownData).forEach(id => {
            const message = localStorage.getItem(countdownData[id].message);
            const targetDate = localStorage.getItem(countdownData[id].targetDate);
            if (message) document.getElementById(countdownData[id].message).value = message;
            if (targetDate) document.getElementById(countdownData[id].targetDate).value = targetDate;
        });
        function saveData(id) {
            const message = document.getElementById(countdownData[id].message).value;
            const targetDate = document.getElementById(countdownData[id].targetDate).value;
            localStorage.setItem(countdownData[id].message, message);
            localStorage.setItem(countdownData[id].targetDate, targetDate);
        }
        Object.keys(countdownData).forEach(id => {
            document.getElementById(countdownData[id].message).addEventListener('input', () => saveData(id));
            document.getElementById(countdownData[id].targetDate).addEventListener('input', () => saveData(id));
        });
        function showCountdown(id) {
            const message = document.getElementById(countdownData[id].message).value;
            const targetDateInput = document.getElementById(countdownData[id].targetDate);
            const targetDateValue = targetDateInput.value;
            const now = new Date();
            let targetDate = targetDateValue ? new Date(targetDateValue) : new Date(2024, 9, 1);
            const diff = targetDate - now;
            const days = Math.floor(diff / (1000 * 60 * 60 * 24));
            const hours = Math.floor((diff % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
            const minutes = Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60));
            const seconds = Math.floor((diff % (1000 * 60)) / 1000);
            document.getElementById(`countdownElement${id}`).innerHTML = `${message}${days}天${String(hours).padStart(2, '0')}:${String(minutes).padStart(2, '0')}:${String(seconds).padStart(2, '0')}`;
        }
        Object.keys(countdownData).forEach(id => {
            showCountdown(id);
            setInterval(() => showCountdown(id), 1000);
        });
        let data = JSON.parse(localStorage.getItem('genshinData')) || [];
        const characterTable = document.getElementById("characterTable");
        function renderTable() {
            characterTable.innerHTML = `
                <caption>
                    <button type="button" onclick="dialogAddCharacter.show()" style="float: left;">添加角色</button>
                    <span>原神升级计划数据表</span>
                    <button type="button" onclick="deleteSelectedRows()" style="float: right;">删除选中</button>
                </caption>
                <tr>
                    <th>序号</th>
                    <th>元素</th>
                    <th>角色</th>
                    <th>等级</th>
                    <th>命座</th>
                    <th style="width:100px;">天赋</th>
                    <th style="width:400px;">备注</th>
                    <th>选择</th>
                </tr>
            `;
            let row = 1;
            let lastElement = null;
            data.forEach((elementData, i) => elementData.characters.forEach((character, j) => {
                const newRow = characterTable.insertRow();
                newRow.insertCell().textContent = row++;
                if (elementData.element !== lastElement) {
                    const elementCell = newRow.insertCell();
                    elementCell.rowSpan = elementData.characters.length;
                    elementCell.textContent = elementData.element;
                    lastElement = elementData.element;
                }
                newRow.insertCell().textContent = character.role;
                newRow.insertCell().innerHTML = `<span class="editable" onclick="editField('level', ${i}, ${j})">${character.level}</span>`;
                newRow.insertCell().innerHTML = `<span class="editable" onclick="editField('constellation', ${i}, ${j})">${character.constellation}</span>`;
                newRow.insertCell().innerHTML = `<span class="editable" onclick="editField('talent', ${i}, ${j})">${character.talent}</span>`;
                newRow.insertCell().innerHTML = `<span class="editable" onclick="editField('note', ${i}, ${j})">${character.note}</span>`;
                newRow.style.backgroundColor = getElementColor(elementData.element);
                newRow.insertCell().innerHTML = `<input type="checkbox" ${character.selected ? 'checked' : ''} onchange="updateCheckboxStatus(this, ${i}, ${j})">`;
            }));
        }
        function getElementColor(element) {
            switch (element) {
                case "火": return "#FF0000";
                case "水": return "#0000FF";
                case "风": return "#00FFFF";
                case "雷": return "#800080";
                case "草": return "#008000";
                case "冰": return "#ADD8E6";
                case "岩": return "#FFFF00";
                default: return "#FFFFFF";
            }
        }
        renderTable();
        function addCharacter() {
            const element = document.getElementById("element").value;
            const role = document.getElementById("role").value;
            const level = document.getElementById("level").value;
            const constellation = document.getElementById("constellation").value;
            const talent = document.getElementById("talent").value;
            const note = document.getElementById("note").value;
            if (!element || !role || !level || !constellation || !talent || !note) {
                alert("请填写所有字段");
                return;
            }
            const newCharacter = { role, level: parseInt(level), constellation, talent, note };
            let elementExists = false;
            data.forEach(d => {
                if (d.element === element) {
                    d.characters.push(newCharacter);
                    elementExists = true;
                }
            });
            if (!elementExists) data.push({ element, characters: [newCharacter] });
            localStorage.setItem('genshinData', JSON.stringify(data));
            renderTable();
            document.getElementById("element").value = "";
            document.getElementById("role").value = "";
            document.getElementById("level").value = "";
            document.getElementById("constellation").value = "";
            document.getElementById("talent").value = "";
            document.getElementById("note").value = "";
        }
        function updateCheckboxStatus(checkbox, elementIndex, characterIndex) {
            data[elementIndex].characters[characterIndex].selected = checkbox.checked;
            localStorage.setItem('genshinData', JSON.stringify(data));
        }
        function deleteSelectedRows() {
            data = data.filter(elementData => {
                elementData.characters = elementData.characters.filter(character => !character.selected);
                return elementData.characters.length > 0;
            });
            localStorage.setItem('genshinData', JSON.stringify(data));
            renderTable();
        }
        function editField(field, elementIndex, characterIndex) {
            const newValue = prompt("请输入新的值:", data[elementIndex].characters[characterIndex][field]);
            if (newValue !== null) {
                data[elementIndex].characters[characterIndex][field] = newValue;
                localStorage.setItem('genshinData', JSON.stringify(data));
                renderTable();
            }
        }
    </script>
</body>
</html>

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/1986092.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

Java斗地主--index1 (0801)

今天遇到一个很有意思的游戏–斗地主&#xff0c;那么下面就开始实现斗地主啦&#xff01;&#xff01;&#xff01; package Demo_YY;public class PockerIndex {public static void main(String[] args) {start();}public static void start(){String pocker[] new String[…

C语言中整数类型及其类型转换

1.数据的存储和排列 是的&#xff0c;在C语言中&#xff0c;整数类型通常以补码&#xff08;twos complement&#xff09;形式存储在内存中。这是因为补码表示法在处理有符号整数的加减运算上更为简便和高效。 基本类型所占字节数&#xff1a; 大端方式存储 就相当于我们平时的…

Android 自定义View(二):画布、画笔、路径(遮罩)以及Sufaceview

目录 1&#xff09;画布是什么&#xff1f;画布如何使用&#xff1f; 2&#xff09;画笔是什么&#xff0c;画笔如何生成呢&#xff1f; 3&#xff09;如何画圆、画文字、画矩形 4&#xff09;路径&#xff08;Path&#xff09;遮罩 5&#xff09;Sufaceview&#xff08;使用…

UWB实操:使用 litepoint 定制UWB信号,BPRF,HPRF,mean PRF,SFD,gap,PSDU,STS

使用 litepoint 定制UWB信号 预备知识: Technology选择UWBP VSG -> WaveGen ->UWBP Wave settings G

2024.8.6 作业

1> 使用消息队列完成两个进程之间相互通信 snd.c #include <myhead.h>struct msgbuf {long mtype;char mtext[1024]; };#define SIZE sizeof(struct msgbuf)-sizeof(long)int main(int argc,const char *argv[]) {pid_t pid fork();if(pid-1){perror("fork er…

【C++入门(下)】—— 我与C++的不解之缘(二)

前言 接上篇&#xff0c;继续来学习C&#xff0c;本篇内容大概有 引用&#xff0c;inline 和 nullptr。 六、引用&#xff1a; 6.1、引用的定义 引用不是新定义一个变量&#xff0c;而是给已存在的变量取了一个别名&#xff0c;编译器不会为引用变量开辟内存空间&#xff0c;它…

SQL基础命令

目录 查看版本 root登录 查看用户 数据库清单 创建数据库 选择数据库 删除数据库 退出 MySQL 查看版本 mysql --version root登录 mysql -uroot -p 查看用户 select user()&#xff1b; 数据库清单 show databases; 创建数据库 # create database xxx; create dat…

heic格式批量转化jpg,这几个方法简单好上手!

在这个数字化时代&#xff0c;手机摄影已成为我们记录生活、分享美好的重要方式。然而&#xff0c;苹果用户可能会遇到一个头疼的问题——拍摄的照片默认保存为HEIC格式&#xff0c;这种格式虽然能大幅节省存储空间&#xff0c;但在非苹果设备上查看或编辑时却不太方便。别担心…

8月开始|660/880/严选题45天强化带刷计划

45天刷完《严选题》《660》《880》&#xff1f; 可能吗&#xff1f; 是不是又在制造焦虑&#xff1f; 别急&#xff0c;其实严选题《660》《880》的核心知识点并不多&#xff0c;45天完全能够刷完&#xff0c;下面就是帮大家整理总结的这些习题册的核心知识点和重点题&#…

【多线程-从零开始-肆】线程安全、加锁和死锁

进程状态 进程状态&#xff1a; 就绪&#xff1a;正在 CPU 上执行&#xff0c;或者随时可以去 CPU 上执行阻塞&#xff1a;暂时不能参与 CPU 的执行 Java 的线程&#xff0c;对应状态做了更详细的区分&#xff0c;不仅仅是就绪和阻塞了 六种状态&#xff1a; NEW 当前 Thread…

vulnhub靶机实战_DC-8

一、靶机下载 靶机下载链接汇总&#xff1a;https://download.vulnhub.com/使用搜索功能&#xff0c;搜索dc类型的靶机即可。本次实战使用的靶机是&#xff1a;DC-8系统&#xff1a;Debian下载链接&#xff1a;https://download.vulnhub.com/dc/DC-8.zip 二、靶机启动 下载完…

C++编程基础的学习

Qt跨平台特性 在深入探讨C编程的基础知识之前&#xff0c;我们首先需要了解Qt框架的跨平台特性。Qt是一个功能强大的跨平台应用程序框架&#xff0c;它允许开发者编写一次代码&#xff0c;然后在多个平台上运行&#xff0c;包括Windows、macOS、Linux、iOS、Android等。这种跨…

Linux网络编程3

并发服务器 1.TCP多进程并发服务器 服务器端&#xff1a; 客户端&#xff1a; 2.TCP多线程服务器 服务器端&#xff1a; 客户机端&#xff1a; 需要学习的函数还有 1. send() 函数 send() 函数用于在套接字上发送数据。它是网络编程中发送数据到对端的主要函数之一。 函数…

人像修图-高低频磨皮

原理 将图像分成高频图层&#xff08;处理纹理细节&#xff09;和低频图层&#xff08;处理光影和光影&#xff09;&#xff0c;以达到修饰时互不干扰 步骤 复制两个图层 在低频图层建立高斯模糊&#xff1a;滤镜->模糊->高斯模糊。注意半径一般根据皮肤占比&#xf…

day 20进程

一、程序和进程的区别 程序&#xff1a;保存在磁盘空间中的的一段代码的集合&#xff0c;死的 进程&#xff1a;是一个程序动态执行的过程&#xff0c;包括进程的创建、调度和消亡的过程 二、进程相关的命令 PID:进程的标识符(进程的ID) PPID:父进程的ID号 三、进程的创建…

redis的数据结构与对象

简单动态字符串 文章目录 简单动态字符串SDS的定义SDS的结构图示结构SDS字段解析SDS的特点 SDS和字符串的区别常数复杂度获取字符串的长度杜绝缓冲区的溢出减少修改字符串时的内存分配次数二进制安全兼容部分c字符串函数总结 链表链表和链表节点的实现链表节点&#xff08;list…

全球手机基站位置数据,包含(2G-5G)基站

OpenCellID 是一个由社区维护的项目&#xff0c;它提供了一个开放的数据集&#xff0c;包含全球各地的移动通信基站信息。这个项目对于需要获取蜂窝网络基础设施详细信息的研究人员、开发者以及组织来说非常有用。这些信息可以被用来进行各种分析和应用开发&#xff0c;例如改进…

Python 在开发中的设计模式有哪些?怎样使用?

大家好&#xff01;我是爱摸鱼的小鸿&#xff0c;关注我&#xff0c;收看每期的编程干货。 今天我们要聊点硬核的——设计模式。不过&#xff0c;不用担心&#xff0c;我会带着热情来跟你分享这些看似枯燥的知识点。让我们一起从“代码搬砖工”蜕变成“代码艺术家”吧&#xff…

Redis面试题大全

文章目录 Redis有哪几种基本类型Redis为什么快&#xff1f;为什么Redis6.0后改用多线程?什么是热key吗&#xff1f;热key问题怎么解决&#xff1f;什么是热Key&#xff1f;解决热Key问题的方法 什么是缓存击穿、缓存穿透、缓存雪崩&#xff1f;缓存击穿缓存穿透缓存雪崩 Redis…

python爬虫预备知识三-多进程

python实现多进程的方法&#xff1a;fork、multiprocessing模块创建多进程。 os.fork方法 os.fork方法只适合于unix/linux系统&#xff0c;不支持windows系统。 fork方法调用一次会返回两次&#xff0c;原因在于操作系统将当前进程&#xff08;父进程&#xff09;复制出一份…