Unnamed pipe Create: int pipe(int fd[2]); Function: Create and process an unnamed pipe in the kernel, and generate two file descriptors (fd[0] for reading, fd[1] for writing) Return value: 0 for success, -1 for failure fd: the resulting file descriptor Read: the read data will disappear When the write terminal exists: read data will return […]
Tag: com
[Docker] Compose container arrangement & LNMP on the cloud
Article directory What is Docker-Compose Download and install official website Official website download Install uninstall Compose core concept a file two elements three steps Compose common commands Django + Mysql + Redis + Nginx deployment deployment architecture Build django container – – – dockerfile writing Build Nginx container docker-compose arranges containers Django project configuration custom_web […]
[17] Alphabet combination of island number and phone number
*Content from leetcode 1. Number of islands Subject requirements Given a 2D grid consisting of ‘1’ (land) and ‘0’ (water), please count the number of islands in the grid. Islands are always surrounded by water, and each island can only be formed by connecting horizontally and/or vertically adjacent land. Also, you can assume that the […]
Database+chatGPT3.5 optimization, indexing, commenting, writing SQL is just a matter of one sentence
Introduction ChatGPT was restless in March, and Microsoft was restless, so Yong should be restless? Impossible, absolutely impossible. To put it simply, Brother Yong successfully integrated chatGPT3.5 into bg-tinkle software in March and released version v1.0.5. After the integration of bg-tinkle, operations such as database modification, statistics, and deletion are all in one sentence, which […]
BPI-R3 development board – uboot compilation
1. Get the source code https://github.com/mtk-openwrt/u-boot 2. Compilation steps The compilation environment is ubuntu 18.04. For the cross-compilation toolchain, I use the toolchain generated by openwrt compilation and set it to the environment variable, as follows: export PATH=$PATH:/root/mt8976/BPI-R3-OPENWRT-V21.02.3-main/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl/bin export STAGING_DIR=/root/mt8976/BPI-R3-OPENWRT-V21.02.3-main/staging_dir 1. Configuration make mt7986a_bpir3_sd_defconfig. It can be seen from the command that the uboot is […]
React component lists three major attributes – Props
1. Introduction to Props 1. Each component object has a props attribute 2. All attributes of component tags are stored in props 3. Pass the changed data from the outside of the component to the inside of the component through the label attribute 2. Basic use of props <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> […]
[linux] CentOS 7 error: yum command reports “Cannot find a valid baseurl for repo: base/7/x86_6” or cannot access the Internet
1. Error reporting 2. Reason for error The system cannot parse the yum source for the following reasons The virtual machine cannot access the Internet! You need to check the network configuration to confirm that you can access the Internet and then look at the second situation Check if you can access the Internet: ping […]
React component life cycle and DOM Diffing algorithm
1. Export life cycle Requirements: Define components to implement the following functions Make the specified text do show/hide gradient animation From being fully visible to completely disappearing, it takes 2S Click the “Dead” button to uninstall the component from the interface <!– Prepare a “container” –> <div id=”test”></div> \t <script type=”text/babel”> //Create component //Lifecycle callback […]
C51 single-chip microcomputer development heart-shaped lamp water lamp (C language)
Using the Keil uVision4 programming program, create a simulation circuit in Proteus 8 Professional Simulation circuit Hexadecimal style pattern int a[][8] = { 0x01,0x02,0x04,0x08,0x10,0x20,0x40,0x80, 0x03,0x06,0x0c,0x18,0x30,0x60,0xc0,0x80, 0x07,0x0e,0x1c,0x38,0x70,0xe0,0xc0,0x80, 0x0f, 0x1e, 0x3c, 0x78, 0xf0, 0xe0, 0xc0, 0x80, 0xfc,0xf9,0xf3,0xe7,0xcf,0x9f,0x3f,0x7f, }; Delay function void delay(unsigned int x) { while(x–); } Loop call function led1() refers to operate the P0 port, […]
Imitation dark horse review project (2. Commodity query cache String)
1. What is caching? The data exchange buffer (cache) is a temporary place to store data, and generally has relatively high read and write performance. Caching can greatly reduce the read and write pressure on the server caused by concurrent access by users. 2. Add merchant cache cache model caching process Code @Service public class […]