【炫酷登录界面】详解5款高级的前端登录页面及实现源码(附完整源码)

news/2024/5/20 4:02:41/文章来源:https://blog.csdn.net/hdp134793/article/details/131251093

写在前面
其实好早之前我就想写这篇文章了,也有些网友还会私信我,说有时候公司要求登录页面的改造,问我能不能出一期关于登录页的文章,于是乎我也是拖到这个时候才整理出来,其实每篇文章的效果内容我都是自己亲自去测试的,也是为了给大家提供一个真实有效的代码环境,既然出品必出精品,炫酷高级的登录界面分享与你。
涉及知识点
好看大气的登录页面,高级炫酷登录界面,5款登录界面源码分享,web登录页面制作,如何实现高级登录页面,如何设置透明遮罩,div实现水平垂直居中,CSS动画效果,登录动态切换效果,高科技登录按钮,动态炫酷登录界面实现,animation实现动态登录按钮效果。
效果展示
还是不多说以下五款主题,我们直接上效果,觉得不喜欢的可以直接跳过哈!

  • 樱粉登录界面
  • 星空登录界面
  • 渐变紫登录界面
  • 高级科技登录界面
  • 大气切换登录界面

樱粉渐变登录界面:
在这里插入图片描述

星空登录界面:
在这里插入图片描述
渐变紫登录界面:
在这里插入图片描述

高级科技登录界面(第4节有动效图):

在这里插入图片描述

大气山河登录界面(第5节有动效图):

在这里插入图片描述

版权声明:原创于CSDN博主-拄杖盲学轻声码,有疑惑可去留言私信哟!

目录

  • 1、樱粉登录界面(尾部有完整代码)
    • A、背景线性渐变
    • B、登录框水平垂直居中
    • C、完整代码段
      • Html完整代码
      • Css完整代码
  • 2、星空登录界面
    • A、设置背景图片
    • B、设置登录透明
    • C、完整代码
      • Html代码
      • CSS代码
  • 3、渐变紫登录界面
    • A、背景线性渐变
    • B、登录区线性渐变及左右模块
    • C、完整代码
      • Html代码
      • Css代码
  • 4、高级科技登录界面
    • A、背景深色系渐变
    • B、按钮炫酷动画
    • C、完整代码
      • Html代码
      • Css代码
  • 5、高端大气动态登录界面
    • A、登录注册来回切换动态效果实现
    • B、完整代码
      • Html代码
      • Css代码
  • 6、写在后面与彩蛋
    • 【写在后面】
    • 【彩蛋区】

其实风格实现都是差不多的,我们平时缺的可能就是这设计灵感,具体实现代码及思路如下:

1、樱粉登录界面(尾部有完整代码)

A、背景线性渐变

首先我们做的背景色要比较的好看,核心在于样式的设置,我针对背景色设置了linear-gradient线性渐变,其中核心样式代码如下:

background-image: linear-gradient(to right, #fbc2eb, #a6c1ee);

设置完整体效果如下:
在这里插入图片描述

B、登录框水平垂直居中

设置完背景之后我们就要创建一个登录区域,核心在于位置是水平垂直居中,其核心样式代码如下:

 left: 50%;  top: 50%;  transform: translate(-50%, -50%); 

如下所示水平垂直居中效果:
在这里插入图片描述

后面的input和啥的可以自己加哈:

C、完整代码段

Html完整代码

<div class="container"><div class="login-wrapper"><div class="header">Login</div><div class="form-wrapper"><input type="text" name="username" placeholder="username" class="input-item"><input type="password" name="password" placeholder="password" class="input-item"><div class="btn">Login</div></div><div class="msg">Don't have account?<a href="#">Sign up</a></div></div></div>

Css完整代码

/* 更多请关注CSDN博主-拄杖盲学轻声码 */
* {margin: 0;padding: 0;}html {height: 100%;}body {height: 100%;}.container {height: 100%;background-image: linear-gradient(to right, #fbc2eb, #a6c1ee);}.login-wrapper {background-color: #fff;width: 358px;height: 588px;border-radius: 15px;padding: 0 50px;position: relative;left: 50%;top: 50%;transform: translate(-50%, -50%);}.header {font-size: 38px;font-weight: bold;text-align: center;line-height: 200px;}.input-item {display: block;width: 100%;margin-bottom: 20px;border: 0;padding: 10px;border-bottom: 1px solid rgb(128, 125, 125);font-size: 15px;outline: none;}.input-item:placeholder {text-transform: uppercase;}.btn {text-align: center;padding: 10px;width: 100%;margin-top: 40px;background-image: linear-gradient(to right, #a6c1ee, #fbc2eb);color: #fff;}.msg {text-align: center;line-height: 88px;}a {text-decoration-line: none;color: #abc1ee;}

整体效果:
在这里插入图片描述

2、星空登录界面

A、设置背景图片

我这边是针对body进行了background-image的属性设置,这块你们可以随意调整成自己的背景图,图片一换就是你自己的风格了。
核心代码块(我是基于本地图片加载的):

background: url('img/bgimg.jpg') no-repeat;
background-size: 100% 100%;

效果如下所示:
在这里插入图片描述

B、设置登录透明

其实很多人知道设置透明遮罩background有一个rgba设置属性,但是今天我还要介绍另一种方式的哈,就是background-color的#颜色设置8位,其中前六位为颜色,后两位表示透明度的百分比;

background: rgba(0, 0, 0, 0.6);	/*rgba设置透明层*/
background-color: #00000060;	/*八位颜色位设置透明层*/

其中上面的两种设置效果是一样的,如下图所示:
在这里插入图片描述

C、完整代码

Html代码

 <div id="login_box"><h2>LOGIN</h2><div id="input_box"><input type="text" placeholder="请输入用户名"></div><div class="input_box"><input type="password" placeholder="请输入密码"></div><button>登录</button><br></div>

CSS代码

/* 更多请关注CSDN博主-拄杖盲学轻声码 */body {background: url('img/bgimg.jpg') no-repeat;background-size: 100% 140%;}#login_box {width: 20%;height: 400px;background: rgba(0, 0, 0, 0.6);/*rgba设置透明层*/background-color: #00000060;/*八位颜色位设置透明层*/margin: auto;margin-top: 10%;text-align: center;border-radius: 10px;padding: 50px 50px;}h2 {color: #ffffff90;margin-top: 5%;}#input-box {margin-top: 5%;}span {color: #fff;}input {border: 0;width: 60%;font-size: 15px;color: #fff;background: transparent;border-bottom: 2px solid #fff;padding: 5px 10px;outline: none;margin-top: 10px;}button {margin-top: 50px;width: 60%;height: 30px;border-radius: 10px;border: 0;color: #fff;text-align: center;line-height: 30px;font-size: 15px;background-image: linear-gradient(to right, #30cfd0, #330867);}#sign_up {margin-top: 45%;margin-left: 60%;}a {color: #b94648;}

最终效果如下所示:
在这里插入图片描述

3、渐变紫登录界面

A、背景线性渐变

这个和第一个有点像,主要还是配色的好看,我采用body设置线性渐变
Body背景渐变设置

background-image: linear-gradient(to bottom right, rgb(114, 135, 254), rgb(130, 88, 186));

B、登录区线性渐变及左右模块

先设置大的背景色为紫色,然后设置登录左边模块背景渐变:

background-image: linear-gradient(to bottom right, rgb(118, 76, 163), rgb(92, 103, 211));

设置完A/B之后如下图:
在这里插入图片描述

细心的网友会发现不垂直居中嘛,所以可以自己设置哈。

C、完整代码

Html代码

<body><div class="login-container"><div class="left-container"><div class="title"><span>登录</span></div><div class="input-container"><input type="text" name="username" placeholder="用户名"><input type="password" name="password" placeholder="密码"></div><div class="message-container"><span>忘记密码</span></div></div><div class="right-container"><div class="regist-container"><span class="regist">注册</span></div><div class="action-container"><span>提交</span></div></div></div>
</body>

Css代码

/* 更多请关注CSDN博主-拄杖盲学轻声码 */* {padding: 0;margin: 0;}html {height: 100%;}body {background-image: linear-gradient(to bottom right, rgb(114, 135, 254), rgb(130, 88, 186));}.login-container {width: 600px;height: 315px;margin: 0 auto;margin-top: 10%;border-radius: 15px;box-shadow: 0 10px 50px 0px rbg(59, 45, 159);background-color: rgb(95, 76, 194);}.left-container {display: inline-block;width: 330px;height: calc(100% - 120px);border-top-left-radius: 15px;border-bottom-left-radius: 15px;padding: 60px;background-image: linear-gradient(to bottom right, rgb(118, 76, 163), rgb(92, 103, 211));}.title {color: #fff;font-size: 18px;font-weight: 200;}.title span {border-bottom: 3px solid rgb(237, 221, 22);}.input-container {padding: 20px 0;}input {border: 0;background: none;outline: none;color: #fff;margin: 20px 0;display: block;width: 100%;padding: 5px 0;transition: .2s;border-bottom: 1px solid rgb(199, 191, 219);}input:hover {border-bottom-color: #fff;}::-webkit-input-placeholder {color: rgb(199, 191, 219);}.message-container {font-size: 14px;transition: .2s;color: rgb(199, 191, 219);cursor: pointer;}.message-container:hover {color: #fff;}.right-container {width: 145px;display: inline-block;height: calc(100% - 120px);vertical-align: top;padding: 60px 0;}.regist-container {text-align: center;color: #fff;font-size: 18px;font-weight: 200;}.regist-container span {border-bottom: 3px solid rgb(237, 221, 22);}.action-container {font-size: 10px;color: #fff;text-align: center;position: relative;top: 200px;}.action-container span {border: 1px solid rgb(237, 221, 22);padding: 10px;display: inline;line-height: 20px;border-radius: 20px;position: absolute;bottom: 10px;left: calc(72px - 20px);transition: .2s;cursor: pointer;}.action-container span:hover {background-color: rgb(237, 221, 22);color: rgb(95, 76, 194);}

最终效果如下:
在这里插入图片描述

版权声明:原创于CSDN博主-拄杖盲学轻声码,有疑惑可去留言私信哟!

4、高级科技登录界面

A、背景深色系渐变

这块其实我把颜色给调深了,然后登录模块设置了一个背景色+阴影效果,核心代码如下:
主体Body:

background: linear-gradient(#141e30, #243b55);

登录模块:

background-color: #0c1622;
margin: 100px auto;
border-radius: 10px;
box-shadow: 0 15px 25px 0 rgba(0, 0, 0, .6);

设置完效果如下所示:
在这里插入图片描述

B、按钮炫酷动画

其实这套登录皮肤的灵魂就是这个动态的按钮效果,主要是应用了css的animation动画效果,其实说句实话,都知道有这个动画属性,就是不会用起来,没有别人用的那么炫酷,那么这个时候你就要去多看看别人的设计思想了,所以我还是特别喜欢和大家分享一些思路和方法,代码只是为了让你更好的消化和理解。
在这边的思想其实就是我设置了四个标签,每个标签都设置了动画属性,然后给他们一个等间隔的时间差,这样四个动画一起跑就会形成一个动画转圈的效果,你可以拿着这个核心代码去试试看效果就知道了,核心代码如下:

.btn>span {position: absolute;}.btn>span:nth-child(1) {width: 100%;height: 2px;background: -webkit-linear-gradient(left, transparent, #03e9f4);left: -100%;top: 0px;animation: line1 1s linear infinite;}@keyframes line1 {50%,100% {left: 100%;}}.btn>span:nth-child(2) {width: 2px;height: 100%;background: -webkit-linear-gradient(top, transparent, #03e9f4);right: 0px;top: -100%;animation: line2 1s 0.25s linear infinite;}@keyframes line2 {50%,100% {top: 100%;}}.btn>span:nth-child(3) {width: 100%;height: 2px;background: -webkit-linear-gradient(left, #03e9f4, transparent);left: 100%;bottom: 0px;animation: line3 1s 0.75s linear infinite;}@keyframes line3 {50%,100% {left: -100%;}}.btn>span:nth-child(4) {width: 2px;height: 100%;background: -webkit-linear-gradient(top, transparent, #03e9f4);left: 0px;top: 100%;animation: line4 1s 1s linear infinite;}@keyframes line4 {50%,100% {top: -100%;}}

C、完整代码

Html代码

<div class="loginBox"><h2>login</h2><form action=""><div class="item"><input type="text" required><label for="">userName</label></div><div class="item"><input type="password" required><label for="">password</label></div><button class="btn">submit<span></span><span></span><span></span><span></span></button></form></div>

Css代码

/* 更多特效请关注CSDN博主-拄杖盲学轻声码 */* {margin: 0;padding: 0;}a {text-decoration: none;}input,button {background: transparent;border: 0;outline: none;}body {height: 100vh;background: linear-gradient(#141e30, #243b55);display: flex;justify-content: center;align-items: center;font-size: 16px;color: #03e9f4;}.loginBox {width: 400px;height: 364px;background-color: #0c1622;margin: 100px auto;border-radius: 10px;box-shadow: 0 15px 25px 0 rgba(0, 0, 0, .6);padding: 40px;box-sizing: border-box;}h2 {text-align: center;color: aliceblue;margin-bottom: 30px;font-family: 'Courier New', Courier, monospace;}.item {height: 45px;border-bottom: 1px solid #fff;margin-bottom: 40px;position: relative;}.item input {width: 100%;height: 100%;color: #fff;padding-top: 20px;box-sizing: border-box;}.item input:focus+label,.item input:valid+label {top: 0px;font-size: 2px;}.item label {position: absolute;left: 0;top: 12px;transition: all 0.5s linear;}.btn {padding: 10px 20px;margin-top: 30px;color: #03e9f4;position: relative;overflow: hidden;text-transform: uppercase;letter-spacing: 2px;left: 35%;}.btn:hover {border-radius: 5px;color: #fff;background: #03e9f4;box-shadow: 0 0 5px 0 #03e9f4,0 0 25px 0 #03e9f4,0 0 50px 0 #03e9f4,0 0 100px 0 #03e9f4;transition: all 1s linear;}.btn>span {position: absolute;}.btn>span:nth-child(1) {width: 100%;height: 2px;background: -webkit-linear-gradient(left, transparent, #03e9f4);left: -100%;top: 0px;animation: line1 1s linear infinite;}@keyframes line1 {50%,100% {left: 100%;}}.btn>span:nth-child(2) {width: 2px;height: 100%;background: -webkit-linear-gradient(top, transparent, #03e9f4);right: 0px;top: -100%;animation: line2 1s 0.25s linear infinite;}@keyframes line2 {50%,100% {top: 100%;}}.btn>span:nth-child(3) {width: 100%;height: 2px;background: -webkit-linear-gradient(left, #03e9f4, transparent);left: 100%;bottom: 0px;animation: line3 1s 0.75s linear infinite;}@keyframes line3 {50%,100% {left: -100%;}}.btn>span:nth-child(4) {width: 2px;height: 100%;background: -webkit-linear-gradient(top, transparent, #03e9f4);left: 0px;top: 100%;animation: line4 1s 1s linear infinite;}@keyframes line4 {50%,100% {top: -100%;}}

整体实现效果:
在这里插入图片描述

5、高端大气动态登录界面

其实这个登录框我只是想和大家分享一下登录区域其实可以将大的背景色设置为局部的,给人感觉有放大的气势,也不失为一种视觉效果,这个实现过程其实和之前的差不多,我就不做过多的讲解,但是我要讲的是切换效果,点击登录和注册之间的切换。

A、登录注册来回切换动态效果实现

这个里面其实我主要是写了两套,然后通过click点击事件,给页面的元素添加或移除样式属性,核心JS代码如下:

const signInBtn = document.getElementById("signIn");const signUpBtn = document.getElementById("signUp");const fistForm = document.getElementById("form1");const secondForm = document.getElementById("form2");const container = document.querySelector(".container");signInBtn.addEventListener("click", () => {container.classList.remove("right-panel-active");});signUpBtn.addEventListener("click", () => {container.classList.add("right-panel-active");});fistForm.addEventListener("submit", (e) => e.preventDefault());secondForm.addEventListener("submit", (e) => e.preventDefault());

实现效果如下:
在这里插入图片描述

B、完整代码

Html代码

<div class="container right-panel-active"><!-- Sign Up --><div class="container__form container--signup"><form action="#" class="form" id="form1"><h2 class="form__title">Sign Up</h2><input type="text" placeholder="User" class="input" /><input type="email" placeholder="Email" class="input" /><input type="password" placeholder="Password" class="input" /><button class="btn">Sign Up</button></form></div><!-- Sign In --><div class="container__form container--signin"><form action="#" class="form" id="form2"><h2 class="form__title">Sign In</h2><input type="email" placeholder="Email" class="input" /><input type="password" placeholder="Password" class="input" /><a href="#" class="link">Forgot your password?</a><button class="btn">Sign In</button></form></div><!-- Overlay --><div class="container__overlay"><div class="overlay"><div class="overlay__panel overlay--left"><button class="btn" id="signIn">Sign In</button></div><div class="overlay__panel overlay--right"><button class="btn" id="signUp">Sign Up</button></div></div></div></div>

Css代码

/* 更多特效请关注CSDN博主-拄杖盲学轻声码 */:root {/* COLORS */--white: #e9e9e9;--gray: #333;--blue: #0367a6;--lightblue: #008997;/* RADII */--button-radius: 0.7rem;/* SIZES */--max-width: 758px;--max-height: 420px;font-size: 16px;font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;}body {align-items: center;background-color: var(--white);background: url("img/bgimg3.jpg");background-attachment: fixed;background-position: center;background-repeat: no-repeat;background-size: cover;display: grid;height: 100vh;place-items: center;}.form__title {font-weight: 300;margin: 0;margin-bottom: 1.25rem;}.link {color: var(--gray);font-size: 0.9rem;margin: 1.5rem 0;text-decoration: none;}.container {background-color: var(--white);border-radius: var(--button-radius);box-shadow: 0 0.9rem 1.7rem rgba(0, 0, 0, 0.25),0 0.7rem 0.7rem rgba(0, 0, 0, 0.22);height: var(--max-height);max-width: var(--max-width);overflow: hidden;position: relative;width: 100%;}.container__form {height: 100%;position: absolute;top: 0;transition: all 0.6s ease-in-out;}.container--signin {left: 0;width: 50%;z-index: 2;}.container.right-panel-active .container--signin {transform: translateX(100%);}.container--signup {left: 0;opacity: 0;width: 50%;z-index: 1;}.container.right-panel-active .container--signup {animation: show 0.6s;opacity: 1;transform: translateX(100%);z-index: 5;}.container__overlay {height: 100%;left: 50%;overflow: hidden;position: absolute;top: 0;transition: transform 0.6s ease-in-out;width: 50%;z-index: 100;}.container.right-panel-active .container__overlay {transform: translateX(-100%);}.overlay {background-color: var(--lightblue);background: url("img/bgimg3.jpg");background-attachment: fixed;background-position: center;background-repeat: no-repeat;background-size: cover;height: 100%;left: -100%;position: relative;transform: translateX(0);transition: transform 0.6s ease-in-out;width: 200%;}.container.right-panel-active .overlay {transform: translateX(50%);}.overlay__panel {align-items: center;display: flex;flex-direction: column;height: 100%;justify-content: center;position: absolute;text-align: center;top: 0;transform: translateX(0);transition: transform 0.6s ease-in-out;width: 50%;}.overlay--left {transform: translateX(-20%);}.container.right-panel-active .overlay--left {transform: translateX(0);}.overlay--right {right: 0;transform: translateX(0);}.container.right-panel-active .overlay--right {transform: translateX(20%);}.btn {background-color: var(--blue);background-image: linear-gradient(90deg, var(--blue) 0%, var(--lightblue) 74%);border-radius: 20px;border: 1px solid var(--blue);color: var(--white);cursor: pointer;font-size: 0.8rem;font-weight: bold;letter-spacing: 0.1rem;padding: 0.9rem 4rem;text-transform: uppercase;transition: transform 80ms ease-in;}.form>.btn {margin-top: 1.5rem;}.btn:active {transform: scale(0.95);}.btn:focus {outline: none;}.form {background-color: var(--white);display: flex;align-items: center;justify-content: center;flex-direction: column;padding: 0 3rem;height: 100%;text-align: center;}.input {background-color: #fff;border: none;padding: 0.9rem 0.9rem;margin: 0.5rem 0;width: 100%;}@keyframes show {0%,49.99% {opacity: 0;z-index: 1;}50%,100% {opacity: 1;z-index: 5;}}

JS代码

 const signInBtn = document.getElementById("signIn");const signUpBtn = document.getElementById("signUp");const fistForm = document.getElementById("form1");const secondForm = document.getElementById("form2");const container = document.querySelector(".container");signInBtn.addEventListener("click", () => {container.classList.remove("right-panel-active");});signUpBtn.addEventListener("click", () => {container.classList.add("right-panel-active");});fistForm.addEventListener("submit", (e) => e.preventDefault());secondForm.addEventListener("submit", (e) => e.preventDefault());

整体实现效果上面已经给出动态图。
还有什么想要了解的大家都可以留言哈,博主尽量在能力范围内给你们安排上哈!!!

版权声明:原创于CSDN博主-拄杖盲学轻声码,有疑惑可去留言私信哟!

6、写在后面与彩蛋

【写在后面】

最终呈现出来给大家的效果如上图所示的,这个也是博主精心整理出来的文章,喜欢的话可以在彩蛋区给博主一些小小的支持,爱你们哟!。

【彩蛋区】

希望我写的文章能给您带来启发,如果觉得博主的东西对您有帮助的话,期待您的支持与谅解,童叟无欺,创作不易,欢迎您来打榜!!!皇榜入口点击此处(已联网备案)

皇榜效果如下:
在这里插入图片描述

时光不弃,有我有你,2023年我们一起加油哈!!!

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

如若内容造成侵权/违法违规/事实不符,请联系dt猫网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

java【抽象类与接口】

抽象类与接口 1 抽象类1.1 定义与使用1.2 抽象类和抽象方法使用原则 2 接口2.1 定义2.2 使用规则 3. JDK中内置接口3.1 Comparable接口3.2 Cloneable接口 抽象类与接口的对比 前言&#xff1a;如果强制要求子类必须覆写一些方法&#xff0c;则就会用到抽象类和抽象方法 1 抽象类…

OpenCV 笔记_5

文章目录 笔记_5特征点匹配DMatch 存放匹配结果DescriptorMatcher::match 特征点描述子&#xff08;一对一&#xff09;匹配DescriptorMatcher::knnMatch 特征点描述子&#xff08;一对多&#xff09;匹配DescriptorMatcher::radiusMatch 特征点描述子&#xff08;一对多&#…

C语言之指针详解(8)

目录 本章重点 1. 字符指针 2. 数组指针 3. 指针数组 4. 数组传参和指针传参 5. 函数指针 6. 函数指针数组 7. 指向函数指针数组的指针 8. 回调函数 9. 指针和数组面试题的解析 指针和数组笔试题解析 #include<stdio.h> int main() {//一维数组int a[] { 1,2,…

flv 报错 Unsupported codec in video frame: 12

视频播放器播放 flv 报错 [TransmuxingController] > DemuxException: type CodecUnsupported, info Flv: Unsupported codec in video frame: 12 原因 主要是因为我们的播放器不支持 H.265 视频编码&#xff1b; 解决办法 方法一&#xff1a;将设备端的视频编码改为 …

瑞萨RA系列mcu学习笔记--RTT-pwm驱动

方案1&#xff1a;Studio 2.2.6和使用了RASC3.5下使用pwm驱动 开发环境必须说一下&#xff0c;本人在在开发环境的问题上栽了一个跟头&#xff0c; 使用最新版的RTT Studio 2.2.6和使用了RASC4.0的版本生成的公共编译ok&#xff0c;但是一下载到mcu就直接不能运行&#xff1a…

记录一下RocketMQ中遇见的 连环大坑!!!差点没把我摔死

目录 环境&#xff1a;Win10 &#xff0c; 不是 linux 首先我遇见的第一个问题是&#xff1a; No route info of this topic 问题原因&#xff1a; PS&#xff1a; 64位系统环境下&#xff0c;如果软件在安装时安装路径默认c:\progarmfiles即为64位&#xff0c;默认c:\pr…

【备战秋招】每日一题:5月13日美团春招第三题:题面+题目思路 + C++/python/js/Go/java带注释

为了更好的阅读体检&#xff0c;为了更好的阅读体检&#xff0c;&#xff0c;可以查看我的算法学习博客第三题-火车调度 在线评测链接:P1288 题目描述 塔子哥是一位火车车厢调度员。 这一天&#xff0c;一列带有 n 个编号车厢的列车进站了&#xff0c;编号为 1\rightarrow …

kafka 报错 - Cannot assign requested address

背景 在华为云服务器上跑了 zookeeper 和 kafka 的 broker&#xff0c;想内外网分流&#xff0c;重点就是做不到从外网去消费&#xff0c;比如用自己的 windows 笔记本去消费。 配置 server.properties 的 listener 为 broker 所在机子的的内网 IP 后&#xff0c;终于能 star…

ECC算法学习(一)算法公式

ECC 一、ECC简介优缺点运用 二、算法理论基础1. 椭圆曲线的加法2. 椭圆曲线的二倍运算3. 同余运算4. 有限域5. 乘法逆元 三、算法公式1、有限域的负元2、有限域的加法&#xff0c; P Q P Q PQ3. 斜率计算&#xff08;PQ即要计算P点切线&#xff0c;需要求导&#xff09;4. 椭…

【位图布隆过滤器海量数据面试题】

文章目录 1 位图2 布隆过滤器 1 位图 首先我们来看看一个腾讯的面试题&#xff1a;给40亿个不重复的无符号整数&#xff0c;没排过序。给一个无符号整数&#xff0c;如何快速判断一个数是否在这40亿个数中。 分析&#xff1a; 40亿个不重复整形数据&#xff0c;大概有160亿字节…

Axios和Spring MVC[前端和后端的请求和响应处理]

在前后端交互中&#xff0c;Axios和Spring MVC扮演着不同的角色&#xff0c;分别负责前端和后端的请求和响应处理。它们之间的作用如下&#xff1a; Axios&#xff08;前端&#xff09;&#xff1a; 发送HTTP请求&#xff1a;前端使用Axios库发送HTTP请求到后端。可以使用Axi…

机器学习实践(1.1)XGBoost分类任务

前言 XGBoost属于Boosting集成学习模型&#xff0c;由华盛顿大学陈天齐博士提出&#xff0c;因在机器学习挑战赛中大放异彩而被业界所熟知。相比越来越流行的深度神经网络&#xff0c;XGBoost能更好的处理表格数据&#xff0c;并具有更强的可解释性&#xff0c;还具有易于调参…

hard fault on thread: mqtt0解决办法

rt thread版本4.1.0 使用paho mqtt软件包 运行一段时间后出现 psr: 0x21000000 r00: 0x5036fc8f r01: 0x5036fc88 r02: 0x00000000 r03: 0x5036fc8f r04: 0x00000007 r05: 0x00000063 r06: 0x00005f70 r07: 0x2001f1d8 r08: 0xdeadbeef r09: 0xdeadbeef r10: 0xdeadbeef r11…

关于Java SSM框架的面试题

一、Spring面试题 1、Spring 在ssm中起什么作用&#xff1f; Spring&#xff1a;轻量级框架作用&#xff1a;Bean工厂&#xff0c;用来管理Bean的生命周期和框架集成。两大核心&#xff1a;1、IOC/DI(控制反转/依赖注入) &#xff1a;把dao依赖注入到service层&#xff0c;se…

28.vite

目录 1 一些概念 1.1 单页面应用程序SPA 1.2 vite 2 初始化vite项目 3 项目中的文件 1 一些概念 1.1 单页面应用程序SPA 单页面应用程序是只有一个页面的前端&#xff0c;切换页面通过前端路由来切换 特点如下 实现了前后端分离&#xff0c;后端仅出接口&#…

动态规划III (买股票-121、122、123、188、309)

CP121 买股票的最佳时机 题目描述&#xff1a; 给定一个数组 prices &#xff0c;它的第 i 个元素 prices[i] 表示一支给定股票第 i 天的价格。你只能选择 某一天 买入这只股票&#xff0c;并选择在 未来的某一个不同的日子 卖出该股票。设计一个算法来计算你所能获取的最大利…

YOLOv5-7.0添加解耦头

Decoupled Head Decoupled Head是由YOLOX提出的用来替代YOLO Head&#xff0c;可以用来提升目标检测的精度。那么为什么解耦头可以提升检测效果呢&#xff1f; 在阅读YOLOX论文时&#xff0c;找到了两篇引用的论文&#xff0c;并加以阅读。 第一篇文献是Song等人在CVPR2020发表…

【59天|503.下一个更大元素II ● 42. 接雨水】

503.下一个更大元素II class Solution { public:vector<int> nextGreaterElements(vector<int>& nums) {stack<int> st;int n nums.size();vector<int> res (n, -1);for(int i0; i<2*n;i){while(!st.empty()&&nums[i%n]>nums[st.t…

随机的乐趣和游戏

1、猜数字游戏 #GuessingGame.py import random the_number random.randint(1, 10) print("计算机已经在1到10之间随机生成了一个数字&#xff0c;") guess int(input("请你猜猜是哪一个数字: ")) while guess ! the_number:if guess > the_number:p…

PHP设计模式21-工厂模式的讲解及应用

文章目录 前言基础知识简单工厂模式工厂方法模式抽象工厂模式 详解工厂模式普通的实现更加优雅的实现 总结 前言 本文已收录于PHP全栈系列专栏&#xff1a;PHP快速入门与实战 学会好设计模式&#xff0c;能够对我们的技术水平得到非常大的提升。同时也会让我们的代码写的非常…