几款很好看的爱心表白代码(动态)

news/2024/4/29 17:22:26/文章来源:https://blog.csdn.net/weixin_61370021/article/details/127777393

分享几款好看的爱心表白代码

    • ❤️爱心代码❤️(C语言)
    • ❤️流动爱心❤️(html+css+js)
    • ❤️线条爱心❤️(html+css+js)
    • ❤️biu表白爱心❤️(html+css+js)
    • ❤️matlab爱心函数❤️(需安装matlab r2022)

❤️爱心代码❤️(C语言)

在这里插入图片描述

#include <stdio.h>
#include <Windows.h>int main()
{float x, y, a;for (y = 1.5; y > -1.5; y -= 0.1){for (x = -1.5; x < 1.5; x += 0.05){a = x * x + y * y - 1;putchar(a * a * a - x * x * y * y * y <= 0.0 ? '*' : ' ');}system("color 0c");putchar('\n');}return 0;
}

❤️流动爱心❤️(html+css+js)

在这里插入图片描述

  • HTML部分:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE> New Document </TITLE><META NAME="Generator" CONTENT="EditPlus"><META NAME="Author" CONTENT=""><META NAME="Keywords" CONTENT=""><META NAME="Description" CONTENT=""><style>html, body {height: 100%;padding: 0;margin: 0;background: #000;
}
canvas {position: absolute;width: 100%;height: 100%;
}</style></HEAD><BODY><canvas id="pinkboard"></canvas><script>/** Settings*/
var settings = {particles: {length:   500, // maximum amount of particlesduration:   2, // particle duration in secvelocity: 100, // particle velocity in pixels/seceffect: -0.75, // play with this for a nice effectsize:      30, // particle size in pixels},
};/** RequestAnimationFrame polyfill by Erik Möller*/
(function(){var b=0;var c=["ms","moz","webkit","o"];for(var a=0;a<c.length&&!window.requestAnimationFrame;++a){window.requestAnimationFrame=window[c[a]+"RequestAnimationFrame"];window.cancelAnimationFrame=window[c[a]+"CancelAnimationFrame"]||window[c[a]+"CancelRequestAnimationFrame"]}if(!window.requestAnimationFrame){window.requestAnimationFrame=function(h,e){var d=new Date().getTime();var f=Math.max(0,16-(d-b));var g=window.setTimeout(function(){h(d+f)},f);b=d+f;return g}}if(!window.cancelAnimationFrame){window.cancelAnimationFrame=function(d){clearTimeout(d)}}}());/** Point class*/
var Point = (function() {function Point(x, y) {this.x = (typeof x !== 'undefined') ? x : 0;this.y = (typeof y !== 'undefined') ? y : 0;}Point.prototype.clone = function() {return new Point(this.x, this.y);};Point.prototype.length = function(length) {if (typeof length == 'undefined')return Math.sqrt(this.x * this.x + this.y * this.y);this.normalize();this.x *= length;this.y *= length;return this;};Point.prototype.normalize = function() {var length = this.length();this.x /= length;this.y /= length;return this;};return Point;
})();/** Particle class*/
var Particle = (function() {function Particle() {this.position = new Point();this.velocity = new Point();this.acceleration = new Point();this.age = 0;}Particle.prototype.initialize = function(x, y, dx, dy) {this.position.x = x;this.position.y = y;this.velocity.x = dx;this.velocity.y = dy;this.acceleration.x = dx * settings.particles.effect;this.acceleration.y = dy * settings.particles.effect;this.age = 0;};Particle.prototype.update = function(deltaTime) {this.position.x += this.velocity.x * deltaTime;this.position.y += this.velocity.y * deltaTime;this.velocity.x += this.acceleration.x * deltaTime;this.velocity.y += this.acceleration.y * deltaTime;this.age += deltaTime;};Particle.prototype.draw = function(context, image) {function ease(t) {return (--t) * t * t + 1;}var size = image.width * ease(this.age / settings.particles.duration);context.globalAlpha = 1 - this.age / settings.particles.duration;context.drawImage(image, this.position.x - size / 2, this.position.y - size / 2, size, size);};return Particle;
})();/** ParticlePool class*/
var ParticlePool = (function() {var particles,firstActive = 0,firstFree   = 0,duration    = settings.particles.duration;function ParticlePool(length) {// create and populate particle poolparticles = new Array(length);for (var i = 0; i < particles.length; i++)particles[i] = new Particle();}ParticlePool.prototype.add = function(x, y, dx, dy) {particles[firstFree].initialize(x, y, dx, dy);// handle circular queuefirstFree++;if (firstFree   == particles.length) firstFree   = 0;if (firstActive == firstFree       ) firstActive++;if (firstActive == particles.length) firstActive = 0;};ParticlePool.prototype.update = function(deltaTime) {var i;// update active particlesif (firstActive < firstFree) {for (i = firstActive; i < firstFree; i++)particles[i].update(deltaTime);}if (firstFree < firstActive) {for (i = firstActive; i < particles.length; i++)particles[i].update(deltaTime);for (i = 0; i < firstFree; i++)particles[i].update(deltaTime);}// remove inactive particleswhile (particles[firstActive].age >= duration && firstActive != firstFree) {firstActive++;if (firstActive == particles.length) firstActive = 0;}};ParticlePool.prototype.draw = function(context, image) {// draw active particlesif (firstActive < firstFree) {for (i = firstActive; i < firstFree; i++)particles[i].draw(context, image);}if (firstFree < firstActive) {for (i = firstActive; i < particles.length; i++)particles[i].draw(context, image);for (i = 0; i < firstFree; i++)particles[i].draw(context, image);}};return ParticlePool;
})();/** Putting it all together*/
(function(canvas) {var context = canvas.getContext('2d'),particles = new ParticlePool(settings.particles.length),particleRate = settings.particles.length / settings.particles.duration, // particles/sectime;// get point on heart with -PI <= t <= PIfunction pointOnHeart(t) {return new Point(160 * Math.pow(Math.sin(t), 3),130 * Math.cos(t) - 50 * Math.cos(2 * t) - 20 * Math.cos(3 * t) - 10 * Math.cos(4 * t) + 25);}// creating the particle image using a dummy canvasvar image = (function() {var canvas  = document.createElement('canvas'),context = canvas.getContext('2d');canvas.width  = settings.particles.size;canvas.height = settings.particles.size;// helper function to create the pathfunction to(t) {var point = pointOnHeart(t);point.x = settings.particles.size / 2 + point.x * settings.particles.size / 350;point.y = settings.particles.size / 2 - point.y * settings.particles.size / 350;return point;}// create the pathcontext.beginPath();var t = -Math.PI;var point = to(t);context.moveTo(point.x, point.y);while (t < Math.PI) {t += 0.01; // baby steps!point = to(t);context.lineTo(point.x, point.y);}context.closePath();// create the fillcontext.fillStyle = '#ea80b0';context.fill();// create the imagevar image = new Image();image.src = canvas.toDataURL();return image;})();// render that thing!function render() {// next animation framerequestAnimationFrame(render);// update timevar newTime   = new Date().getTime() / 1000,deltaTime = newTime - (time || newTime);time = newTime;// clear canvascontext.clearRect(0, 0, canvas.width, canvas.height);// create new particlesvar amount = particleRate * deltaTime;for (var i = 0; i < amount; i++) {var pos = pointOnHeart(Math.PI - 2 * Math.PI * Math.random());var dir = pos.clone().length(settings.particles.velocity);particles.add(canvas.width / 2 + pos.x, canvas.height / 2 - pos.y, dir.x, -dir.y);}// update and draw particlesparticles.update(deltaTime);particles.draw(context, image);}// handle (re-)sizing of the canvasfunction onResize() {canvas.width  = canvas.clientWidth;canvas.height = canvas.clientHeight;}window.onresize = onResize;// delay rendering bootstrapsetTimeout(function() {onResize();render();}, 10);
})(document.getElementById('pinkboard'));</script></BODY>
</HTML>

❤️线条爱心❤️(html+css+js)

在这里插入图片描述

  • HTML部分:
<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8" /><title>流动爱心表白</title></head><!-- css部分 --><style>body {background-color: #000;margin: 0;overflow: hidden;background-repeat: no-repeat;
}</style><body><!-- 绘画爱心 --><canvas id="canvas" width="1400" height="600"></canvas><!-- js部分 --></body><script>
var canvas = document.getElementById("canvas");
canvas.width = window.innerWidth;
canvas.height = window.innerHeight;
// Initialize the GL context
var gl = canvas.getContext('webgl');
if (!gl) {console.error("Unable to initialize WebGL.");
}
//Time step
var dt = 0.015;
//Time
var time = 0.0;
//************** Shader sources **************
var vertexSource = `
attribute vec2 position;
void main() {gl_Position = vec4(position, 0.0, 1.0);
}
`;var fragmentSource = `
precision highp float;
uniform float width;
uniform float height;
vec2 resolution = vec2(width, height);
uniform float time;
#define POINT_COUNT 8
vec2 points[POINT_COUNT];
const float speed = -0.5;
const float len = 0.25;
float intensity = 0.9;
float radius = 0.015;
//https://www.shadertoy.com/view/MlKcDD
//Signed distance to a quadratic bezier
float sdBezier(vec2 pos, vec2 A, vec2 B, vec2 C){    vec2 a = B - A;vec2 b = A - 2.0*B + C;vec2 c = a * 2.0;vec2 d = A - pos;float kk = 1.0 / dot(b,b);float kx = kk * dot(a,b);float ky = kk * (2.0*dot(a,a)+dot(d,b)) / 3.0;float kz = kk * dot(d,a);      float res = 0.0;float p = ky - kx*kx;float p3 = p*p*p;float q = kx*(2.0*kx*kx - 3.0*ky) + kz;float h = q*q + 4.0*p3;if(h >= 0.0){ h = sqrt(h);vec2 x = (vec2(h, -h) - q) / 2.0;vec2 uv = sign(x)*pow(abs(x), vec2(1.0/3.0));float t = uv.x + uv.y - kx;t = clamp( t, 0.0, 1.0 );// 1 rootvec2 qos = d + (c + b*t)*t;res = length(qos);}else{float z = sqrt(-p);float v = acos( q/(p*z*2.0) ) / 3.0;float m = cos(v);float n = sin(v)*1.732050808;vec3 t = vec3(m + m, -n - m, n - m) * z - kx;t = clamp( t, 0.0, 1.0 );// 3 rootsvec2 qos = d + (c + b*t.x)*t.x;float dis = dot(qos,qos);res = dis;qos = d + (c + b*t.y)*t.y;dis = dot(qos,qos);res = min(res,dis);qos = d + (c + b*t.z)*t.z;dis = dot(qos,qos);res = min(res,dis);res = sqrt( res );}return res;
}
//http://mathworld.wolfram.com/HeartCurve.html
vec2 getHeartPosition(float t){return vec2(16.0 * sin(t) * sin(t) * sin(t),-(13.0 * cos(t) - 5.0 * cos(2.0*t)- 2.0 * cos(3.0*t) - cos(4.0*t)));
}
//https://www.shadertoy.com/view/3s3GDn
float getGlow(float dist, float radius, float intensity){return pow(radius/dist, intensity);
}
float getSegment(float t, vec2 pos, float offset, float scale){for(int i = 0; i < POINT_COUNT; i++){points[i] = getHeartPosition(offset + float(i)*len + fract(speed * t) * 6.28);}vec2 c = (points[0] + points[1]) / 2.0;vec2 c_prev;float dist = 10000.0;for(int i = 0; i < POINT_COUNT-1; i++){//https://tinyurl.com/y2htbwkmc_prev = c;c = (points[i] + points[i+1]) / 2.0;dist = min(dist, sdBezier(pos, scale * c_prev, scale * points[i], scale * c));}return max(0.0, dist);
}
void main(){vec2 uv = gl_FragCoord.xy/resolution.xy;float widthHeightRatio = resolution.x/resolution.y;vec2 centre = vec2(0.5, 0.5);vec2 pos = centre - uv;pos.y /= widthHeightRatio;//Shift upwards to centre heartpos.y += 0.02;float scale = 0.000015 * height;float t = time;//Get first segmentfloat dist = getSegment(t, pos, 0.0, scale);float glow = getGlow(dist, radius, intensity);vec3 col = vec3(0.0);//White corecol += 10.0*vec3(smoothstep(0.003, 0.001, dist));//Pink glowcol += glow * vec3(0.94,0.14,0.4);//Get second segmentdist = getSegment(t, pos, 3.4, scale);glow = getGlow(dist, radius, intensity);//White corecol += 10.0*vec3(smoothstep(0.003, 0.001, dist));//Blue glowcol += glow * vec3(0.2,0.6,1.0);//Tone mappingcol = 1.0 - exp(-col);//Output to screengl_FragColor = vec4(col,1.0);
}
`;//************** Utility functions **************window.addEventListener('resize', onWindowResize, false);function onWindowResize() {canvas.width = window.innerWidth;canvas.height = window.innerHeight;gl.viewport(0, 0, canvas.width, canvas.height);gl.uniform1f(widthHandle, window.innerWidth);gl.uniform1f(heightHandle, window.innerHeight);
}//Compile shader and combine with source
function compileShader(shaderSource, shaderType) {var shader = gl.createShader(shaderType);gl.shaderSource(shader, shaderSource);gl.compileShader(shader);if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {throw "Shader compile failed with: " + gl.getShaderInfoLog(shader);}return shader;
}//From https://codepen.io/jlfwong/pen/GqmroZ
//Utility to complain loudly if we fail to find the attribute/uniform
function getAttribLocation(program, name) {var attributeLocation = gl.getAttribLocation(program, name);if (attributeLocation === -1) {throw 'Cannot find attribute ' + name + '.';}return attributeLocation;
}function getUniformLocation(program, name) {var attributeLocation = gl.getUniformLocation(program, name);if (attributeLocation === -1) {throw 'Cannot find uniform ' + name + '.';}return attributeLocation;
}//************** Create shaders **************//Create vertex and fragment shaders
var vertexShader = compileShader(vertexSource, gl.VERTEX_SHADER);
var fragmentShader = compileShader(fragmentSource, gl.FRAGMENT_SHADER);//Create shader programs
var program = gl.createProgram();
gl.attachShader(program, vertexShader);
gl.attachShader(program, fragmentShader);
gl.linkProgram(program);gl.useProgram(program);//Set up rectangle covering entire canvas 
var vertexData = new Float32Array([-1.0, 1.0, // top left-1.0, -1.0, // bottom left1.0, 1.0, // top right1.0, -1.0, // bottom right
]);//Create vertex buffer
var vertexDataBuffer = gl.createBuffer();
gl.bindBuffer(gl.ARRAY_BUFFER, vertexDataBuffer);
gl.bufferData(gl.ARRAY_BUFFER, vertexData, gl.STATIC_DRAW);// Layout of our data in the vertex buffer
var positionHandle = getAttribLocation(program, 'position');gl.enableVertexAttribArray(positionHandle);
gl.vertexAttribPointer(positionHandle,2, // position is a vec2 (2 values per component)gl.FLOAT, // each component is a floatfalse, // don't normalize values2 * 4, // two 4 byte float components per vertex (32 bit float is 4 bytes)0 // how many bytes inside the buffer to start from
);//Set uniform handle
var timeHandle = getUniformLocation(program, 'time');
var widthHandle = getUniformLocation(program, 'width');
var heightHandle = getUniformLocation(program, 'height');gl.uniform1f(widthHandle, window.innerWidth);
gl.uniform1f(heightHandle, window.innerHeight);function draw() {//Update timetime += dt;//Send uniforms to programgl.uniform1f(timeHandle, time);//Draw a triangle strip connecting vertices 0-4gl.drawArrays(gl.TRIANGLE_STRIP, 0, 4);requestAnimationFrame(draw);
}draw();</script>
</html>

❤️biu表白爱心❤️(html+css+js)

在这里插入图片描述

  • ❤️点这里下载biu爱心表白完整代码❤️
  • HTML部分:
<!DOCTYPE html>
<html lang="en"><head><meta charset="UTF-8"><title>js+html爱心表白动画特效</title><link rel="stylesheet" href="css/love.css"></head><body><div class="container" onselectstart="return false;" unselectable="on" style="-moz-user-select:none;"><div class="body_left"><img src="images/biubiubiu.gif" alt="" ondragstart='return false;'></div><div class="body_center love"><div class="block"><div class="div1"></div><div class="div2"></div><div class="div3"></div><div class="div4"></div></div></div></div><div class="footer"><div class="border"><div class="border-top"></div><div class="border-bottom"></div></div><!-- <div class="copyright"><div id="version"><span>Version:</span>&nbsp;0.0.2</div><div id="createTime"><span>Time:</span>&nbsp;2022/7/13</div><div id="author"><span>&copy;&nbsp;</span>psw</div></div> --></div><script type="text/javascript" src="js/love.js"></script></body>
</html>

❤️matlab爱心函数❤️(需安装matlab r2022)

在这里插入图片描述

function LoveFunc
LoveFunchdl=@(x,a)(x.^2).^(1/3)+0.9.*((3.3-x.^2).^(1/2)).*sin(a.*pi.*x);
hold on
grid on
axis([-3 3,-2 4])
x=-1.8:0.005:1.8;
text(0,3.3,'$f(x)=x^{\frac{2}{3}}+0.9(3.3-x^2)^{\frac{1}{2}}\sin(\alpha\pi x)$',...'FontSize',13,'HorizontalAlignment','center','Interpreter','latex');
txt2=text(-0.35,2.9,'','FontSize',13,'HorizontalAlignment','left','Interpreter','latex','tag','alphadata');
for a=1:0.01:20delete(findobj('type','line'))AlphaString=['$\alpha=',num2str(a),'$'];Color=([1.0000 0.4902 0.6627]-[0.2118 0.4667 0.9961]).*(a/20)+[0.2118 0.4667 0.9961];set(txt2,'string',AlphaString)plot(x,LoveFunchdl(x,a),'color',Color,'LineWidth',1.2);pause(0.003)
end
end

❤️❤️属于我们计算机的浪漫,快去分享给你心中最可爱的TA吧 ❤️❤️
❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️❤️

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

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

相关文章

LSTM--火灾温度预测

&#x1f368; 本文为&#x1f517;365天深度学习训练营 中的学习记录博客&#x1f366; 参考文章地址&#xff1a; 365天深度学习训练营-第R2周&#xff1a;LSTM-火灾温度预测&#x1f356; 作者&#xff1a;K同学啊一句话介绍LSTM&#xff0c;它是RNN的进阶版&#xff0c;如果…

静态路由———初学

文章目录实验需求:关键命令&#xff1a;静态路由默认路由实验配置接下来是配置pc的IP地址静态路由的配置保存实验需求: PC1 在 LAN1 中&#xff0c;PC2 在 LAN2 中&#xff0c;使用静态路由实现 pc1 和 pc2 之间的互相通信 本实验使用Cisco Packet Tracer 模拟器搭建 所有的路…

公考求的是稳定,搞IT求的是高薪,鱼和熊掌能否兼得?

程序员和公务员&#xff0c;大概是最让大家耳熟能详的两种职业。 这也是中国现代年轻人最具有代表性的两种职业。 程序员是从事程序开发、程序维护的专业人员。一般将程序员分为程序设计人员和程序编码人员&#xff0c;但两者的界限并不非常清楚&#xff0c;特别是在中国。软…

Verilog功能模块——Uart收发

摘要本文分享了一种通用的Uart收发模块&#xff0c;可实现Uart协议所支持的任意波特率&#xff0c;任意位宽数据&#xff08;5~8&#xff09;&#xff0c;任意校验位&#xff08;无校验、奇校验、偶校验、1校验、0校验&#xff09;&#xff0c;任意停止位&#xff08;1、1.5、2…

前端反爬思考,好友从百度搜到了我的文章,链接却是别人的

今天感叹可以改完八阿哥早点下班&#xff0c;在吃饭的时候&#xff0c;就想着自己也写了一段时间了&#xff0c;看看百度这个强大的引擎能不能搜到我的博客文章。 1、发现文章被爬走了 吃饭的时候用手机搜的&#xff0c;感觉还挺开心&#xff0c;我还给朋友炫耀&#xff0c;你看…

Import Error: from torchtext.data import to_map_style_dataset解决方案

大家好,我是爱编程的喵喵。双985硕士毕业,现担任全栈工程师一职,热衷于将数据思维应用到工作与生活中。从事机器学习以及相关的前后端开发工作。曾在阿里云、科大讯飞、CCF等比赛获得多次Top名次。喜欢通过博客创作的方式对所学的知识进行总结与归纳,不仅形成深入且独到的理…

电子统计台账:快速设置产品的排除与保留

目录 1 基础操作 2 设置垂直过滤模板 2.1 排除法 2.2 保留法 3 完成其他设置 4 小提示&#xff1a;项目导入导出 实践中&#xff0c;企业数据文件中可能有很多产品&#xff0c;中间混杂诸如“累计”、“合计”、“报表人”、“企业负责人”等信息。我们需要用简单的操作完…

洛谷千题详解 | P1018 [NOIP2000 提高组] 乘积最大【C++、Python、Java、pascal语言】

博主主页&#xff1a;Yu仙笙 专栏地址&#xff1a;洛谷千题详解 目录 题目描述 输入格式 输出格式 输入输出样例 解析&#xff1a; C源码&#xff1a; Python源码&#xff1a; Pascal源码&#xff1a; Java源码&#xff1a; -------------------------------------------------…

苯丙氨酸甲酯双三氟甲基磺酰亚胺[PheC1][Tf2N]氨基酸酯离子液体

苯丙氨酸甲酯双三氟甲基磺酰亚胺[PheC1][Tf2N]氨基酸酯离子液体 纯度&#xff1a;95% 外观与形状:液体/固体, 储存:存放于惰性气体之中 应避免湿气 (吸湿) 包装规格(Packing):50g、100g、500g 保存方法&#xff1a;密闭&#xff0c;阴凉&#xff0c;通风干燥处 氨基酸酯…

返回Series或DataFrame中指定列中指定数量的最小值nsmallest()函数

【小白从小学Python、C、Java】 【计算机等级考试500强双证书】 【Python-数据分析】 返回Series或DataFrame中 指定列中指定数量的最小值 nsmallest()函数 [太阳]选择题 下列说法错误的是? import pandas as pd mySeries pd.Series([31, 21, 11]) print("【显示】mySer…

Numpy手撸softmax regression

算法介绍 Softmax 回归&#xff08;或多项逻辑回归&#xff09;是将逻辑回归推广到我们想要处理多个类的情况。 在逻辑回归中&#xff0c;我们假设标签是二元的&#xff1a;y(i)∈{0,1}y^{(i)} \in \{0,1\}y(i)∈{0,1},我们使用这样的分类器来区分两种手写数字。 Softmax 回归…

C#项目实战|人脸识别考勤

此文主要通过WinForm来制作的一个人脸识别考勤打卡程序&#xff0c;有兴趣的小伙伴可以接入到打卡机上。 一、实现流程1.1、创建项目1.2、设计页面1.3、创建应用1.4、获取Token及参数解析1.5、与人脸数据比对并展示一、实现流程 1.1、创建项目 打开Visual Studio&#xff0c;右…

值得入手的键盘——Keychron K8 Pro

目录 一、前言 二、介绍 三、上手体验 四、总结 一、前言 在如今&#xff0c;外设产品市场相当火爆的时代&#xff0c;拥有诸多知名的品 牌&#xff0c;而一个新品牌要在竞争非常激烈的情况下站稳脚跟&#xff0c;实属不易。诞生于2017年的 Keychron 以其品质作为高端战略…

【mcuclub】舵机-SG90

一、实物图&#xff08;SG90&#xff09; 二、原理图 编号名称功能1GND电源地&#xff08;棕色线&#xff09;2VCC电源正&#xff08;红色线&#xff09;3I/O信号线&#xff08;黄色线&#xff09; 三、简介 舵机&#xff08;英文叫Servo&#xff09;&#xff0c;是伺服电机的…

WINDOWS核心编程--Windows程序内部运行机制

现代的桌面应用基本上很少使用原始的 Windows API 进行开发了&#xff0c;因为使用原始 API 堆砌出来的应用代码逻辑非常繁琐&#xff0c;特别是窗口消息的处理非常不方便&#xff0c;大多数直接使用 C# 或者 QT 这种跨平台的开发库&#xff0c;而那种直接封装 Windows API 而存…

C语言经典题目之青蛙跳台阶问题

目录 一、问题描述 二、问题分析 1.当n1时 2.当n2时 3.当n3时 4.n4&#xff0c;n5........nn时 三、代码实现 总结 一、问题描述 一只青蛙一次可以跳上 1 级台阶&#xff0c;也可以跳上2 级。求该青蛙跳上一个n 级的台阶总共有多少种跳法。 二、问题分析 青蛙跳台阶&a…

Spring-Aop面向切面编程

文章目录一、简介1、作用2、AOP核心概念3、五种&#xff08;增强&#xff09;通知类型二、AOP入门小案例&#xff08;注解版&#xff09;1.导入坐标(pom.xml)2.制作连接点(原始操作&#xff0c;Dao接口与实现类)3:定义通知类和通知4:定义切入点5:制作切面6:将通知类配给容器并标…

【Linux】第十一章 进程信号(概念+产生信号+阻塞信号+捕捉信号)

&#x1f3c6;个人主页&#xff1a;企鹅不叫的博客 ​ &#x1f308;专栏 C语言初阶和进阶C项目Leetcode刷题初阶数据结构与算法C初阶和进阶《深入理解计算机操作系统》《高质量C/C编程》Linux ⭐️ 博主码云gitee链接&#xff1a;代码仓库地址 ⚡若有帮助可以【关注点赞收藏】…

C++基本知识(二)---函数重载、引用、内联函数、auto关键字

目录 1.函数重载 2.引用 3.内联函数 4.auto关键字(C11) 5.指针空值nullptr(C11) 1.函数重载 重载函数是函数的一种特殊情况&#xff0c;为方便使用&#xff0c;C允许在同一范围中声明几个功能类似的同名函数&#xff0c;但是这些同名函数的形式参数&#xff08;指参数的个…

CEC2015:(二)动态多目标野狗优化算法DMODOA求解DIMP2、dMOP2、dMOP2iso、dMOP2dec(提供Matlab代码)

一、cec2015中测试函数DIMP2、dMOP2、dMOP2iso、dMOP2dec详细信息 CEC2015&#xff1a;动态多目标测试函数之DIMP2、dMOP2、dMOP2iso、dMOP2dec详细信息 二、动态多目标野狗优化算法 多目标野狗优化算法&#xff08;Multi-Objective Dingo Optimization Algorithm&#xff0…