Differences Between Python and C Language

Differences Between Python and C Language

Differences Between Python and C LanguageExplained in Simple Terms by a Northeastern Senior——Py&C—— Understand the differences between Python and C language in just 3 minutes! A Northeastern senior speaks the truth, stop saying you can’t tell them apart! Let’s talk about it. Do any of you feel that when programming languages are mentioned, Python and … Read more

A Review of C++ Smart Pointers: Types, Usage, and Practical Scenarios

A Review of C++ Smart Pointers: Types, Usage, and Practical Scenarios

👆Click the blue text "Linux Armory" at the top, and select "Add to Favorites" in the upper right corner to not miss out on great articles and see valuable content first. 👆FollowLinux Armory, to receive hardcore Linux learning materials and code. Today, let’s revisit smart pointers in C++. In C++ resource management, manually using <span>new</span>/<span>delete</span> … Read more

Comparing Pointers in Go and C/C++

Comparing Pointers in Go and C/C++

This article compares the use of pointers in Go and C/C++, understanding how Go’s pointer design addresses the safety issues inherent in C/C++ while retaining their advantages. Original text:Pointers Made Painless: How Go Solves C/C++’s Biggest Headache[1] Few things in the world possess both strength and fragility in the same characteristic. In the realm of … Read more

A Comprehensive Guide to Linux Server Performance Troubleshooting

A Comprehensive Guide to Linux Server Performance Troubleshooting

A Comprehensive Guide to Linux Server Performance Troubleshooting Server Performance Troubleshooting Introduction: At 2 AM, my phone suddenly buzzed—”CPU usage has soared to 95%!” As an operations engineer, have you ever experienced such a “firefighting” moment? Don’t panic! Master this set of performance troubleshooting “combination punches”, and you can identify the root cause in 3 … Read more

Understanding High Memory Usage in Linux Systems

Understanding High Memory Usage in Linux Systems

During the use of Linux systems, many users find that the system’s memory usage seems to always be high, even shortly after startup, consuming a large amount of memory. This is in stark contrast to the memory management methods of Windows systems, often raising concerns about system performance. This article will delve into the reasons … Read more

Understanding Linux Black Hole and Zero Bytes: A Comprehensive Guide to /dev/null and /dev/zero

Understanding Linux Black Hole and Zero Bytes: A Comprehensive Guide to /dev/null and /dev/zero

If you often browse the default files in Linux, you must have an impression of /dev/null and /dev/zero, or you might have seen shell code like this:> /dev/null 2>&1. It is a special character device file in the Linux system, commonly referred to as the “null device” or “black hole device.” It occupies a fixed … Read more

The Importance of Using the Static Modifier in Embedded Development

The Importance of Using the Static Modifier in Embedded Development

In embedded development, adding the <span>static</span> modifier before variables and functions is a very important practice that primarily serves three core purposes: limiting scope, extending lifespan, and controlling memory allocation. This is particularly crucial for resource-constrained embedded systems that require high reliability. Here is a detailed explanation: 1. Using <span>static</span> for Variables a) Static Local … Read more

What Are the Differences Between str and String in Rust?

What Are the Differences Between str and String in Rust?

In Rust, <span>str</span> and <span>String</span> are two core types for handling text data, and they have essential differences in memory management, ownership, and mutability. The table below summarizes their core differences for quick understanding: Feature <span>String</span> <span>str</span> (<span>&str</span>) Ownership Owns the data No ownership, it is a borrowed reference Mutability Mutable Immutable Storage Location Data … Read more

Exploring Pointers in C Language (Part 5) — Linked Lists: A Perfect Interpretation of Pointer Art

Exploring Pointers in C Language (Part 5) — Linked Lists: A Perfect Interpretation of Pointer Art

After a few busy days, I haven’t had the chance to focus on this topic. Today, on my business trip back to Beijing, I reflected on it and thought it was necessary to back up the linked list. 1. What is a Linked List? A linked list is a data structure composed of a series … Read more

Common GDB Commands for Linux

Common GDB Commands for Linux

1. Common GDB Commands 1. Basic Commands 1.1. Start Debugging gdb test.elf 1.2. View Disassembly # Set style to view disassembly set disassembly-floavor intel disassemble # Disassemble current instruction disassemble $pc, $pc+0x100 1.3. View Functions info functions 1.4. Print Addresses # Print variable address Print function address print &var print test_function 1.5. GDB Remote Connection … Read more