CSS基础笔记

news2024/10/7 8:22:23

第一课

CSS(层叠式样式表);样式规则由 选择器属性 以及 属性值 组成

内联样式表、内嵌样式表、外部样式表

内联样式表

写在标签里 用 style 属性进行表示,优先级比 内嵌外部

<h1 style="color: blue; text-align: center;">内联样式,h1我是蓝色</h1>

内嵌样式表

写在 head 标签内,使用 style 标签包含,优先级比 外部

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>CSS文本属性</title>
    <style>
        /* 选择器{样式} */
        h1 {
            color: red;
        }
        p {
            color: green;
            font-size: 30px;
        }
        .red {
            color: red;
        }
        .blue {
            color: blue;
        }
        .yellow {
            color: yellow;
        }
        .green {
            color: green;
        }
        span{
            font-size: 200px;
        }
    </style>
</head>
<body style="background-image: url(../HTML/材料/img/bj.gif);">
    <div>
        <h1>我是红色</h1>
        <p>我是绿色,字体大小是 30 px</p>
        <h1 style="color: blue; text-align: center;">内联样式,h1我是蓝色</h1>
        <div style="text-align: center;">
            <span class="blue">G</span>
            <span class="red">o</span>
            <span class="yellow">o</span>
            <span class="blue">g</span>
            <span class="green">l</span>
            <span class="red">e</span>
        </div>
    </div>
</body>
</html>

外联样式表

head 标签内,使用 link 标签外链外部文件 .css,优先级较低

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>外联样式表</title>
    <link rel="stylesheet" href="./css/01-02-外联样式表.css">
</head>
<body>
    <h1>你好,世界</h1>
</body>
</html>
/* css文件里面只有样式没有标签 */
body {
    background-image: url(../../HTML/材料/img/bj.gif);
}
h1 {
    color: pink;
    text-align: center;
}

第二课

!importtant 用于定义优先级最高

important 后面 才加 分号

<head>
    <style>
        h1 {
            color: red;
        }
        h2 {
            color: brown !important;
        }
    </style>
</head>
<body>
    <h1 style="color: blue;">你好 世界</h1>
    <h2 style="color: blue;">你好 蓝色</h2>
</body>

标签选择器

就是标签名的选择器,对HTML标签指定样式规则。

p {
    color: red;
}
div {
    color; green;
}

ID选择器

id 的值必须唯一,id 是标签内的一个 属性

格式:#id名 {}

<head>
    <style>
        #id1 {
            color: red;
        }
        #id2 {
            color: blue;
        }
        #id3 {
            color: black;
        }
        #id4 {
            color: green;
        }
    </style>
</head>
<body>
    <h1>id选择器的使用</h1>
    <p id="id1">id选择器</p>
    <p id="id2">id选择器</p>
    <p id="id3">id选择器</p>
    <p id="id4">id选择器</p>
</body>

类选择器

可以为标有特定class值的HTML元素指定样式规则。

css语法:. 类选择器名{}

标签语法:<标签名 class=“类选择器名”>

</head>
	<style>
        .class1 {
            color: red;
            text-align: center;
        }
        .class2 {
            color: green;
            text-align: right;
        }
    </style>
</head>
<body>
    <h1>类选择器</h1>
    <p class="class1">这是class1</p>
    <p class="class2">这是class2</p>
</body>

全局选择器

可以为页面所有的HTML页面的所有元素指定样式

语法:*{}

* {
	margin: 0;
	padding: 0;
}
这里两个清零很重要,因为有的标签有默认的 margin 和 padding
所以写页面的时候,通配符双清零很重要!!!!

群组选择器

语法:选择器名1 选择器名2 选择器名3

        p,div,.class1{
            color: red;
        }
    <h2>群组选择器</h2>
    <p id="xuanzeqi1">这是id选择器</p>
    <div>这是div标签选择器</div>
    <h3 class="class1">这是类选择器</h3>

后代选择器

父子关系的标签

语句:父选择器名 空格 子选择器名 {}

p span {
    color: red;
}
#id1 span {
    color: blue;
}
.class1 span {
    color: green;
}
<h2>后代选择器</h2>
<p><span>后代选择器</span>的应用</p>
<p id="id1"><span>后代选择器</span>的应用</p>
<p class="class1"><span>后代选择器</span>的应用</p>

伪类选择器

用于添加选择器的一些特殊效果,例如HTML元素在不同状态下使用不同的样式。

使用最多的是 连接的伪类选择器

link:未访问连接

visited:已访问链接

hover:鼠标悬停

active:鼠标按下不松的时候

注意 一定要按照顺序link,visited,hover,active的顺序来写

/* text-decoration属性清除默认的下划线 */
a {
    text-decoration: none;
}
a:link {
    color: red;
}
a:visited {
    color: green;
}
a:hover {
    color: blue;
}
a:active {
    color: black;
}
<div>
    <div>
        <a href="#">这是测试</a>
    </div>
</div>

属性选择器

定于属性选择器的语法格式:选择器名[属性名]{}

子串匹配属性选择器

[ab^=“def”] 选择ab属性以def开头的

字体属性

font:简写属性;font-style font-weight font-size font-family;

斜不斜 粗不粗 大不大/高不高 什么样

font-size:字体大小

font-weight:字体粗细

font-family:字体

font-style:字形,italic 斜体

/* 符合属性:简写的方式 */
/* font: font-style font-weight font-size font-family; */
p {
    font-family:'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 24px;
    font-weight: bold;
    font-style: italic;
}

文本属性

color:文本言责

line-height:行高

letter-spacing:字符间距

text-indent:缩进

text-decoration:字体的初始化,none就是空,即清除字体样式

text-align;文本对齐的方式

p {
    text-indent: 2em;
    text-align: left;
    text-decoration: none;
    color: brown;
    line-height: 50px;
}

text-shadow 阴影:水平偏移 垂直偏移 模糊半径 颜色值

水平和垂直正值的是右下,负值是左上

模糊半径不可为负,越小阴影越明显

.title {
    font: italic 700 60px/80px "宋体";
    color: rgba(235, 16, 16, 0.856);
    text-shadow: 10px 10px 1px green;
}

word-wrap 自动换行

.huanhang {
    width: 120px;
    border: 1px solid black;
    /* 多余字进行换行 */
    word-wrap: break-word;
}

font-face 导入自己的字体

@font-face {
    font-family: "guaiti";
    src: url(./css/怪体2.ttf);
}
div {
    font-family: "guaiti";
}
.title {
    text-shadow: 5px 5px 10px gray;
    color: rgb(192, 12, 12);
}
.author {
    color: rgb(231, 149, 163);
    text-shadow: 5px 5px 10px gray;
}

背景属性 background

background-color:背景颜色

background-image:背景图片

background-repeat:背景重复,指定只显示一次背景图像:no-repeat

background-position: right top; 用于指定背景图像的位置

background-origin:设置图片的相对位置,前提是得有padding,值有content-box:相对于内容,padding-box:相对于外盒

div {
	background-color: bisque;
}
.fistword {
	font-size: 300%;
}
body {
    background-image: url(./css/hs.png);
    background-repeat: no-repeat;
    background-size: 100vw 100vh;
}
.warp {
    background-image: url(./css/yks.png);
    background-repeat: no-repeat;
    background-position: left;
    padding: 60px;
    background-origin: padding-box;
}

第三课

列表属性

list-style:简写属性。主要用 none

list-style-image:图像设置列表项标志(即用图片替换 ·

list-style-position:设置列表中列表项标志的位置

list-style-type:设置列表项标志的类型,

/* 主要用于消除列表的默认样式 */
ul {
    list-style: none;
}

/* 用列表做导航栏 */
        ul {
            height: 300px;  
            width: 200px;
            list-style: none;
            text-align: center;
            /* margin: 0; */
            padding: 0;
        }
        ul li {
            height: 30px;
            line-height: 30px;
            display: list-item;
            color: white;
        }

表格属性

border-collapse:设置是否把表格边框合并为单一的边框,值为 collapse

caption-side:设置表格标题的位置

vertical-align:设置文本垂直对齐方式

text-align:设置文本水平对齐方式

border-spacing:属性和 cellspacing 类似

		.class1 {
            border: 1px solid red;
            text-align: center;
            /* 把表格边框合并为单一的边框 */
            border-collapse: collapse;
            /* 表格居中的css实现 */
            margin: 0 auto;
        }
        .class1 tr td {
            border: 1px solid blue;

        }
        .class2 {
            border: 1px solid red;
            border-spacing: 0;
        }
        .class2 tr td {
            border: 1px solid blue;
        }
        .class3 {
            border: 1px solid red;
            border-spacing: 30px;
            float: right;
        }
        .class3 tr td {
            border: 1px solid blue;
        }
	<div>
        <table class="class1">
            <tr>
                <td>item</td>
                <td>item</td>
            </tr>
            <tr>
                <td>item</td>
                <td>item</td>
            </tr>
        </table>

        <table class="class2">
            <tr>
                <td>item</td>
                <td>item</td>
            </tr>
            <tr>
                <td>item</td>
                <td>item</td>
            </tr>
        </table>

        <table class="class3">
            <tr>
                <td>测试</td>
                <td>测试</td>
            </tr>
        </table>
    </div>

在这里插入图片描述

案例

<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>表格、列表课堂任务</title>
    <style>
        table {
            margin: auto auto;
            /* border: 1px solid black; */
            width: 1100px;
            text-align: center;
            vertical-align: middle;
        }
        .top {
            height: 350px;
        }
        .bottom {
            height: 170px;
        }
        .top .font {
            color: white;
            font-size: 80px;
        }
        .bottom td {
            color: rgb(100,149,237);
            font-size: 40px;
        }
        ul {
            height: 300px;  
            width: 200px;
            list-style: none;
            text-align: center;
            /* margin: 0; */
            padding: 0;
        }
        ul li {
            height: 30px;
            line-height: 30px;
            display: list-item;
            color: white;
        }
    </style>
</head>
<body>
    <div>
        <table cellspacing="2">
            <tr class="top">
                <td style="width: 200px;background-color: rgb(60,114,106);">
                    <ul>
                        <li>手机电话卡</li>
                        <li>电视盒子</li>
                        <li>笔记本</li>
                        <li>智能家电</li>
                        <li>健康家居</li>
                        <li>出行儿童</li>
                        <li>路由器手机配件</li>
                        <li>移动电源 插线板</li>
                        <li>耳机 音箱</li>
                        <li>生活 米兔</li>
                    </ul>
                </td>
                <td colspan="3" style="background-color: rgb(100,149,237);" class="font">900×350</td>
            </tr>
            <tr class="bottom">
                <td style="width: 200px;background-color: pink;">200×170</td>
                <td style="background-color: yellow;">316×170</td>
                <td style="background-color: rgb(16,142,37);">316×170</td>
                <td style="background-color: rgb(137,68,206);">316×170</td>
            </tr>
        </table>
    </div>
</body>
</html>

盒子模型

内容内边距边框外边框

width 和 height 只改变内容的大小

margin:外边框

padding:内边距

border:边框

边框 border

宽度:border-width;顺序是 上 右 下 左上下 左右上下 左右上 左右 下

样式:border-style;solid 实线

颜色:border-color;

阴影:box-shadow:水平 垂直 阴影半径 阴影颜色,水平和垂直正值为右下;阴影半径必须为正值,数值越小越清晰;

例如 border:1px solid black;

        div {
            border-style: solid;
            background-color: #ffc;
            /* border-top-width: 2px;
            border-right-width: 3px;
            border-bottom-width: 4px;
            border-left-width: 5px; */

            /* 顺序是上右下左 */
            border-width: 2px 3px 4px 5px;
            width: 300px;
        }
        span {
            /* 顺序是 上 左右 下 */
            border-width: 2px 5px 2px;
        }

边框圆角 border-radius

  • border-radius 属性指定圆角的半径

  • 若只提供一个值,将全部应用到 4 个角

  • 顺序按照 左上、右上、右下、坐下(顺时针)

<div style="border: 5px solid black;
            border-radius: 50px;">
    边框圆角
</div>

如果是圆形的话
长宽相等的正方形
border-radius为长宽的一半

阴影:box-shadow:水平 垂直 阴影半径 阴影颜色,水平和垂直正值为右下;阴影半径必须为正值,数值越小越清晰;

        .top {

            height: 500px;
            border: 5px solid blue;
            border-radius: 10px;
            background-color: rgb(36, 36, 170);
            text-align: center;
            overflow: hidden;
        }
        .bottom {
            background-color: brown;
            border-radius: 2px;
            box-shadow: 10px 10px 5px green;
        }
    <div class="top">
        <div style="height: 100%;width: 800px;margin: 0 auto; border: 3px dotted burlywood;">
            <img src="./img/单元2-6_西安事变.PNG" alt="" style="width: 100%;">
        </div>
    </div>
    <div class="bottom">
        <ul>
            <li>张学良</li>
            <li>杨虎城</li>
            <li>蒋介石</li>
        </ul>
    </div>

在这里插入图片描述

第四课

padding 内边距

padding:内边距的距离值

        div {
            width: 128px;
            height: 128px;
            background-color: #ffc;
            border-style: solid;
            padding: 10px 20px;
        }
    <div style="margin: 0 auto;">
        <img src="./img/淘宝.JPG" alt="淘宝logo" style="width: 128px;height: 128px;">
    </div>

外边距中 inline即行内元素的注意事项

两个水平行内元素之间的外边距 margin-right margin-left 为两个水平行内元素的距离之和

两个垂直行内元素之间的外边距 margin-top margin-bottom 为两个垂直行内元素的距离的最大值的那个

内边距与外边距 案例

        * {
            margin: 0;
            padding: 0;
        }
        .context {
            border: 1px solid blue;
            font-size: 32px;
            text-indent: 1em;
            padding: 5px 0;
            margin: 5px 0;
        }
    <div style="width: 400px; margin: 0 auto;">
        <div>
            <img src="./img/单元2-6_澳门回归.PNG" alt="澳门回归" style="width: 100%;">
        </div>
        <div class="context">
            澳门名称:
        </div>
        <div class="context">
            澳门简历:
        </div>
        <div class="context">
            日期由来:
        </div>
        <div class="context">
            纪念活动:
        </div>
    </div>

在这里插入图片描述

溢出 overflow

hidden:隐藏溢出

scroll:溢出部分用滚动条显示

visible:默认,直接溢出

		div {
            width: 200px; 
            height: 100px;
            border: 1px solid black;
        }
 <div>
        <div>玩的好的后啊维护的基本挖掘哇哦的比较拗口我本地接口带u我表弟把我i第九位那就按可能大家那我叫你 啊啊伟大伟大无法无法无法哇大碗大碗大碗的</div>
        <br><br><br><br><br>
        <div style="overflow: hidden;">玩的好的后啊维护的基本挖掘哇哦的比较拗口我本地接口带u我表弟把我i第九位那就按可能大家那我叫你 啊啊伟大伟大无法无法无法哇大碗大碗大碗的</div>
        <br><br><br><br><br>
        <div style="overflow: scroll;">玩的好的后啊维护的基本挖掘哇哦的比较拗口我本地接口带u我表弟把我i第九位那就按可能大家那我叫你 啊啊伟大伟大无法无法无法哇大碗大碗大碗的</div>
        <br><br><br><br><br>
        <div style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">玩的好的后啊维护的基本挖掘哇哦的比较拗口我本地接口带u我表弟把我i第九位那就按可能大家那我叫你 啊啊伟大伟大无法无法无法哇大碗大碗大碗的</div>
    </div>

浮动 float

left:靠左浮动

right:靠右浮动

none:不浮动

浮动元素需要 父级设置一个宽度,子元素脱离文档流后不得超过父级的宽度,即 子浮动宽度小于父级宽度

浮动元素属性设置后,就算是 inline 即行内元素也会变成 block 即块级元素

float 受父类影响!!!

        div {
            float: left;
            width: 200px; 
            height: 100px;
            border: 1px solid black;
            margin-right: 20px;
        }
    <div style="width: 900px;border: 1px solid red;">
        <div>玩的好的...</div>

        <div style="overflow: hidden;">玩的好.../div>

        <div style="overflow: scroll;">玩的好的...</div>

        <div style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">玩的好...</div>
    </div>

在这里插入图片描述

ul 中 li 变成横向,需要对 li 进行 float:left
        ul {
            list-style: none;
        }
        ul li {
            float: left;
            margin-right: 20px;
            border: 1px solid black;
            padding: 5px;
            cursor: pointer;
            background-color: white;
        }

第五课

相对定位 position:relative

position:relative

是相对于 父级元素 的调动

使用相对定位的盒子对 父级 和 兄弟 并无影响

left:30px

right:30px

top:30px

bottom:30px

        #id1 {
            background-color: blue;
        }
        #id2 {
            position: relative;
            left: 10px;
            top: 10px;
            background-color: red;
        }
    <div id="id1">
        <div id="id2">Box</div>
    </div>

在这里插入图片描述

绝对定位 position:absolute

相对于 浏览器页面 的调用

        #father {
            background-color: blue;
            width: 700px;
            height: 500px;
        }
        #father div {
            background-color: red;
            border: 1px solid yellow;
            width: 500px;
            height: 100px;
            margin: 0 auto;
        }
        #box2 {
            position: absolute;
            top: 0;
            right: 0;
        }
    <div id="father">
        <div>111111111</div>
        <div id="box2">22222222222222</div>
        <div>3333333333333333</div>
    </div>

在这里插入图片描述

当父元素被定位,box2就会以其 父亲 作为绝对定位的基准

        #father {
            background-color: blue;
            width: 700px;
            height: 500px;
            position: relative;		<-----------
        }

        #box2 {
            position: absolute;
            top: 10px;
            right: 10px;
        }

在这里插入图片描述

z-index 属性

用于设置重叠元素的堆叠顺序,默认是0,允许负值。z-index 仅能在定位元素上奏效

越 在上

        #father {
            background-color: black;
            width: 700px;
            height: 500px;
            position: relative;
        }
        #father div {
            border: 1px solid yellow;
            width: 300px;
            height: 100px;
        }
        #box1 {
            background-color: blue;
            position: absolute;
            left: 10px;
        }
        #box2 {
            background-color: red;
            position: absolute;
            left: 60px;
        }
        #box3 {
            background-color: green;
            position: absolute;
            left: 110px;
        }
    <div id="father">
        <div id="box1">box1</div>
        <div id="box2">box2</div>
        <div id="box3">box3</div>
    </div>

在这里插入图片描述

        #box1 {
            background-color: blue;
            position: absolute;
            left: 10px;
            z-index: 1;							<-----------------------
        }
        #box2 {
            background-color: red;
            position: absolute;
            left: 60px;
            z-index: 3;							<-----------------------
            margin-top: 30px;					<-----------------------
        }
        #box3 {
            background-color: green;
            position: absolute;
            left: 110px;
            z-index: 2;							<-----------------------
        }

在这里插入图片描述

小练

在这里插入图片描述

        #wrap {
            width: 800px;
            height: 500px;
            background-color: green;
            margin: 0 auto;
            position: relative;
            border: 2px solid blue;
        }
        #box1 {
            width: 300px;
            height: 200px;
            background-color: gray;
            position: absolute;
            left: 30px;
            top: 30px;
        }
        #box2 {
            width: 300px;
            height: 200px;
            background-color: gray;
            position: absolute;
            right: 30px;
            top: 30px;
        }
        #box3 {
            width: 200px;
            height: 200px;
            border-radius: 100px;
            background-color: blue;
            position: absolute;
            top: 180px;
            left: 300px;
            z-index: 2;
            border: 2px solid white;
        }
        #box4 {
            width: 400px;
            height: 100px;
            background-color: red;
            position: absolute;
            bottom: 30px;
            left: 200px;
            z-index: 1;
            border-radius: 30px;
            border: 2px solid white;
        }
    <div id="wrap">
        <div id="box1">方块1</div>
        <div id="box2">方块2</div>
        <div id="box3">圆形</div>
        <div id="box4">圆角矩形</div>
    </div>

display 属性

inline:行内元素

block:块元素

none:无元素,无元素就是 不显示 里面的内容

    <div>
        <span>默认span</span>
        <span>默认span</span>
        <span style="display: block;">属性改为 block 的span</span>
        <span style="display: block;">属性改为 block 的span</span>
        <div>默认div</div>
        <div>默认div</div>
        <div style="display: inline;">属性改为 inline 的div</div>
        <div style="display: inline;">属性改为 inline 的div</div>
        <div style="display: none;">属性改为 none 的div</div>
    </div>

flex 布局

容器->项目,主轴(水平)、交叉轴(垂直)

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

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

相关文章

osgEarth学习笔记3-第二个Osg QT程序

原文链接 打开QT Creator&#xff0c;新建一个窗口项目。 QT版本如下&#xff1a; 修改pro文件 QT core gui greaterThan(QT_MAJOR_VERSION, 4): QT widgets CONFIG c11 DEFINES QT_DEPRECATED_WARNINGS SOURCES \main.cpp \mainwindow.cpp HEADERS \mainwindow…

2024蓝桥杯每日一题(DFS)

备战2024年蓝桥杯 -- 每日一题 Python大学A组 试题一&#xff1a;奶牛选美 试题二&#xff1a;树的重心 试题三&#xff1a;大臣的差旅费 试题四&#xff1a;扫雷 试题一&#xff1a;奶牛选美 【题目描述】 听说最近两斑点的奶牛最受欢迎&#xff0c;…

Fay数字人<助理版>具体编译步骤,手把手带你避坑 | 多图预警 ( python 3.11 编译环境 超详细教程 )

Fay数字人<助理版>具体编译步骤 系列教程环境描述一、搭建编译环境1、下载anaconda2、下载Fay(带货版)源码 二、Fay编译参数配置&#xff08;手把手教学&#xff09;(一)Fay具体编译步骤(二)配置 aliyun key(三)配置 aliyun 智能语音交互app(四)修改并配置自己的FAY数字…

Java 应用程序监控

Java 监控涉及监控在 Java 上运行的应用程序的关键性能指标&#xff0c;以及 支持 Java 应用程序的服务器。Java 监控可以帮助优化 Java 应用程序的性能&#xff0c;发现和识别以下问题&#xff1a; 导致常见的应用程序问题&#xff0c;并在问题影响最终用户之前解决问题。 Ja…

Vue.js中使用Web Workers来创建一个秒表

在Vue.js中使用Web Workers来创建一个秒表应用可以提高性能&#xff0c;因为Web Workers可以在后台线程中运行&#xff0c;不阻塞主线程。下面是一个简单的Vue.js秒表应用的示例&#xff0c;该应用使用Web Worker来执行计时功能。 首先&#xff0c;我们创建一个Web Worker文件…

ASPICE-SYSSWE

文章主要内容&#xff1a; Automotive SPICE 过程参考模型 SYS.1 需求挖掘 过程ID SYS.1 过程名称 需求挖掘 过程目的 需求挖掘过程的目的是:在产品和/或服务的整个生命周期内收集、处理和跟踪不断变化的利益相关方的需要和需求&#xff0c;从而建立一个需求基线&#x…

5G智慧电力数字孪生可视化平台,推进电力行业数字化转型

5G智慧电力数字孪生可视化平台&#xff0c;推进电力行业数字化转型。5G智慧电力数字孪生可视化平台&#xff0c;正逐渐成为电力行业数字化转型的重要推动力。数字孪生集成了5G通信技术、大数据处理、云计算、人工智能等前沿技术&#xff0c;实现了电力系统的实时监测、数据分析…

SQLite—免费开源数据库系列文章目录

下一篇&#xff1a;SQLite——世界上部署最广泛的免费开源数据库&#xff08;简介&#xff09; ​SQLite系列相关文章较多特开本文为了便于读者阅读特写了本索引和目录之用本文将不断更新中有需要的读者可以收藏本文便于导航到各个专题( 持续更新中......)。收藏一篇等于收藏一…

基础知识学习 -- qnx 系统

QNX是一个基于优先级抢占的系统。 这也导致其基本调度算法相对比较简单。因为不需要像别的通用操作系统考虑一些复杂的“公平性”&#xff0c;只需要保证“优先级最高的线程最优先得到 CPU”就可以了。 基本调度算法 调度算法&#xff0c;是基于优先级的。QNX的线程优先级&a…

鸿蒙开发实战:【Faultloggerd部件】

theme: z-blue 简介 Faultloggerd部件是OpenHarmony中C/C运行时崩溃临时日志的生成及管理模块。面向基于 Rust 开发的部件&#xff0c;Faultloggerd 提供了Rust Panic故障日志生成能力。系统开发者可以在预设的路径下找到故障日志&#xff0c;定位相关问题。 架构 Native In…

jupyter notebook使用教程

首先是打开jupyter notebook 下载安装好之后&#xff0c;直接在命令行中输入‘jupyter notebook’即可跳转到对应页面 还可以进入想要打开的文件夹&#xff0c;然后再文件夹中打开中断&#xff0c;执行‘jupyter notebook’命令&#xff0c;就能够打开对应文件界面的jupyter …

Leetcode 202.快乐数 JAVA

题目 思路 要注意题目中说的无限循环&#xff1a;它是指在求平方和的过程中&#xff0c;会再次出现之前的值&#xff08;想象一个圈&#xff09;&#xff0c;这种情况的时候肯定算不出1来。 所以我们要设定跳出循环的条件是&#xff1a;当平方和结果为1或者出现循环了 出现循…

数字逻辑-时序逻辑电路二——沐雨先生

一、实验目的 &#xff08;1&#xff09;熟悉计数器的逻辑功能及特性。 &#xff08;2&#xff09;掌握计数器的应用。 &#xff08;3&#xff09;掌握时序逻辑电路的分析和设计方法。 二、实验仪器及材料 三、实验原理 1、集成4位计数器74LS161&#xff08;74LS160&#…

区块链宣传推广文案怎么写 区块链宣传推广文案的写作技巧

区块链宣传推广文案的写作技巧 随着区块链技术的不断发展和应用&#xff0c;区块链项目的宣传推广变得越来越重要。而撰写有效的区块链宣传推广文案&#xff0c;则是吸引目标受众关注的关键。下面是一些区块链宣传推广文案的写作技巧&#xff1a; 1. 简明扼要的标题&#xff1…

Docker进阶教程 - 2 Docker部署SpringBoot项目

更好的阅读体验&#xff1a;点这里 &#xff08; www.doubibiji.com &#xff09; 2 Docker部署SpringBoot项目 已经学习了 Dockerfile 了&#xff0c;下面介绍一下如何将 SpringBoot 项目通过 Dockerfile 来部署到 Docker 中。 1 修改项目配置 首先需要准备一个 SpringBo…

c++算法学习笔记 (9) 双指针

1.最长连续不重复子序列 给定一个长度为 n 的整数序列&#xff0c;请找出最长的不包含重复的数的连续区间&#xff0c;输出它的长度。 输入格式 第一行包含整数 n。 第二行包含 n 个整数&#xff08;均在 0∼10^5 范围内&#xff09;&#xff0c;表示整数序列。 输出格式 …

初识Java篇(JavaSE基础语法)(1)

个人主页&#xff08;找往期文章包括但不限于本期文章中不懂的知识点&#xff09;&#xff1a; 我要学编程(ಥ_ಥ)-CSDN博客 目录 前言&#xff1a; 初识Java 运行Java程序 注释 标识符 关键字 数据类型与变量 字面常量 数据类型 变量 类型转换 类型提升 字…

基于springboot在线博客系统源码和论文

社会的发展和科学技术的进步&#xff0c;互联网技术越来越受欢迎。网络计算机的生活方式逐渐受到广大人民群众的喜爱&#xff0c;也逐渐进入了每个用户的使用。互联网具有便利性&#xff0c;速度快&#xff0c;效率高&#xff0c;成本低等优点。 因此&#xff0c;构建符合自己要…

Git Bash命令初始化本地仓库,提交到远程仓库

git init&#xff1a;初始化空仓库 // 初始化一个空仓库或者重新初始化一个存在的仓库 git init git remote // 为当前本地仓库添加一个远程仓库地址 git remote add origin https://gitee.com/xxx/demo.git git pull // 从设置好链接的远程仓库拉去已经存在的数据&#xff0c;…

疯狂送树莓派Pico!与CODESYS和上海晶珩一起,探索慕尼黑上海电子展!

3月20日-3月22日 上海新国际博览中心 E2馆 2200展 上海晶珩 X CODESYS 与您相约慕尼黑上海电子展 上海晶珩&#xff08;EDATEC&#xff09;荣幸宣布&#xff0c;将与全球自动化软件领导者CODESYS公司共同参展2024慕尼黑上海电子生产设备展&#xff01; 届时&#xff0c;我…