Original link: https://xn--qpru0x.cn/t/189
I opened my eyes today and looked out the window. It’s so bright, it’s probably six or seven o’clock, right? I found the phone under the pillow with my hand, ready to check the time, but it didn’t turn on, which was embarrassing. After turning on the machine, I looked at the time “5:59”, and suddenly said “back to the waist”, I had to sigh, I’m so stuck on the time!
Lying in bed, I didn’t want to get up at all, and I didn’t want to go for a “walk”, so I just fell asleep in bed again?. After sleeping for another half hour or so, I woke up. I turned on my phone and tossed the “desktop icons”. I didn’t pay much attention to it before, but today I did, so I spent another half hour arranging the desktop icons.
Around 7:05, I decided to get up, get dressed, brush my teeth and wash. After washing up, I was going to boil a pot of boiling water and soak the bean powder for breakfast; but before that, I went to “Friend B”‘s room to close the door of his room to prevent him from waking up; When I closed the door and found that he was awake, I said “you’re awake, xxx” and went straight to the kitchen to boil water.
After breakfast, I was wondering, “Should I go for a nucleic acid test?” I have been testing for “a week”. To be honest, I can test again every few days, but I think safety comes first, so I go out to prepare for nucleic acid testing. I went, and by the way, I took away the “kitchen waste from yesterday” and threw it away.
When we got there, we waited in line for a while. There were not many people, only about a dozen people. It was very fast. It was the “eldest sister” who registered the nucleic acid for me, and the “little brother” who stabbed me in the throat. I don’t know how often they changed a group of people, or did they just stop changing the testing site?
After the nucleic acid test, I went back to the dormitory and made myself a cup of “red dates and wolfberry tea”, thinking about what to do today? do not know! Later, I thought that the “underpants” that I soaked with washing powder last night have to be washed immediately, so I asked “Friend B” if he wants to use the bathroom now? After getting a negative answer, I went to the bathroom and quickly rubbed my underwear a few times, washed it and put it in the sun.
After I finished washing my panties, I went back to the dining table and sat there “playing with my phone”. “Friend B” also got up at this time. He threw the clothes he was going to wash into the washing machine, then brushed his teeth and washed his face. After finishing his work, he also started today’s breakfast. “Friend B”‘s breakfast was “scrambled eggs with tomatoes ?”, not to mention it was quite fragrant, it just smelled “my stomach is weirdly hungry”.
In the middle, we talked about some “topics”, and then I ended the topic with I was going to go back to the room and toss the computer. Back in the room, I turned on the computer and thought, “I don’t seem to have anything to write about today. If you forget it, I won’t write it anymore”, so I opened the video tutorial at station B ” Introduction to Rust Programming Language (Rust Language/Rust Authoritative Guide) ” Package) [Completed] “.
Yes, I installed, downloaded and configured the “Rust environment” on my computer yesterday. Because of the network speed problem, it took me a few hours to download it yesterday. After I did it, I installed the corresponding “VScode code editor”. “rust extensions” such as rust-analyzer and crates.
If you ask me why I learned “Rust language”, I actually don’t know, maybe it has something to do with a news I saw before ” Cloudflare gave up Nginx and switched to self-developed Pingora software written in Rust ” is also because this news made me I went to Baidu to read the “Rust language”, and then I thought, I have nothing to do recently, and I have nothing to lose, so I started like this.
It’s funny to say that the first lesson I learned today, ” Hello,World!
“, gave an error haha, because I missed the “()” symbol, so I went to Baidu for seven or eight minutes, why did I get an error .
- code show as below:
fn main() { //我把main 后面的“ () ”给漏掉了所以报错, 就挺尴尬的println!("Hello,World!"); }
After the first lesson, I remembered these words. I can’t remember these “words”…I don’t know what they mean.
- as follows
rustc main.rs // 编译成exe 可执行文件cargo new 项目名// 创建新的rust项目cargo build // 好像是检测代码用的? cargo check // 这个也是检查代码是否错误cargo run // 编译并运行
In this first lesson, with such a simple content, I learned more than eleven o’clock from nine o’clock, and then I cooked noodles and ate it. It is still the familiar “buckwheat noodles”, and then added side dishes: “cucumber, carrot, cowpea” and so on (actually, I forgot what the other two dishes are called). Cook for seven or eight minutes, then add salt, monosodium glutamate, dark soy sauce, and it’s ready.
Note: Figure 1
After eating the noodles, I rested for a while. I sat in front of the computer again and watched the following course. Then I started “autism” again. I couldn’t understand anything, I couldn’t understand anything. : “It’s okay if you don’t understand, let’s talk about it later”, I thought about “turning off the video”.
- code show as below:
use std::io; fn main() { println!("猜数!"); println!("猜测一个数"); let mut guess = String::new(); // mut 使变量可变guess 变量名“猜测” String 字符串S需要大写io::stdin().read_line(&mut guess).expect("无法读取行"); println!("你猜测的数是:{}",guess); }
This lesson talks about the “guessing game”, and then how to reference the “library”: ” use std::io;
“; and then explains “variable variables” and “immutable variables”, such as: ” let bianliang =1
” is an immutable variable, if you need “mutability”, you need to add ” mut
” to change, such as: ” let mut bianliang =1
“.
- what have you learned
use std::io; // 引入std 库io 啥的let // 设置变量mut //加入mut 可变变量String::new() // string 百度了一下文本的意思在这里需要“大写” ,new() 新的意思,组合起来新的文本? io::stdin().read_line(&mut guess).expect("无法读取行"); // 直接裂开, io::stdin() 不知道啥意思read_line 百度了意思“阅读线” mut 可变那就是读取行可变? expect 不知道啥意思报错提示? println!("你猜测的数是:{}",guess); // 这里我听懂了,他说“{}” 是占位符,然后里面是存入“guess”变量xxx
I’m just getting started, and they said it’s okay if I don’t understand it. I was just curious, so I understood “what do these words do”. Anyway, I feel that it is quite “difficult to understand”.
In the middle of it, I also fished a bit and went to install an “x-ui V2 panel” for my “VIR five-knife server”, which is convenient for “over the wall” and management that I need.
- script address
bash <(curl -Ls https://raw.githubusercontent.com/vaxilu/x-ui/master/install.sh)
So when it was two o’clock, I didn’t watch the “video tutorial”, I came to write “this dynamic”, and fished, hahaha! ! ! I haven’t slept in the afternoon nap today, and I haven’t read the novel, so let’s drag it to the evening haha! !
- figure 1
This article is reprinted from: https://xn--qpru0x.cn/t/189
This site is for inclusion only, and the copyright belongs to the original author.