20 Common String Operations in Python: How Many Do You Master?

Strings are the most commonly used data type in Python, yet 90% of programmers only utilize 20% of string operations. This article introduces 20 high-frequency, efficient string operation techniques. Mastering them can enhance your code efficiency by tenfold. 1. Basic String Search and Replace (5 Operations) 1. find() vs index() — Finding the Position of … Read more

String Operations in C Language for Embedded Development

String Operations in C Language String operations are a frequent knowledge point in embedded development, where data transmission often requires operations such as copying, concatenating, and splitting strings. This article organizes the commonly used API functions for string operations in C language for easy reference on basic usage. The following header files basically include all … Read more

Chapter 14: Strings in C Language

Chapter 14: Strings in C Language

In C language, a string is essentially an array of characters. A string is composed of characters and is terminated by a <span>'\0'</span> (null character). Chapter 14 covers basic operations on strings, including input, output, concatenation, comparison, length, and more. Below are some common examples and explanations of string operations. 1. Definition and Initialization of … Read more

Detailed Explanation of String Operations in Linux Shell (Length/Find/Replace)

Detailed Explanation of String Operations in Linux Shell (Length/Find/Replace)

(Click the public account above to quickly follow) Source: Cheng Mo http://www.cnblogs.com/chengmo/archive/2010/10/02/1841355.html If you have good articles to submit, please click → here for details When developing shell batch processing programs, string-related operations are often involved. Many command statements, such as: awk and sed, can perform various string operations. In fact, the shell has a … Read more

Learning Python (Part 2) – Basic Syntax

Learning Python (Part 2) - Basic Syntax

As a data analyst, have you encountered these scenarios: You receive a messy dataset and want to quickly extract key information but get stuck on string processing; while cleaning data with pandas, you cause feature extraction chaos due to list slicing errors; when writing analysis scripts, you mess up category mapping because you’re not familiar … Read more

The ‘Text Processor’ in C Language: Character Arrays

The 'Text Processor' in C Language: Character Arrays

Today, let’s talk about character arrays in C language—this “text processor” in the programming world. Character arrays are like your word processor, helping you efficiently store and process text data. Mastering the use of character arrays will make your programming more flexible and powerful. Definition and Initialization of Character Arrays A character array is an … Read more

A Beginner’s Guide to Shell Programming in Linux

A Beginner's Guide to Shell Programming in Linux

Click on the above“Linux Tech Enthusiast” and select “Set as Favorite” High-quality articles delivered promptly ☞【Essentials】ChatGPT 4.0 is unlocked, no limit on questions!!! ☞【Essentials】Notes on Linux self-learned by a Tsinghua senior, top-level quality! ☞【Essentials】Comprehensive list of commonly used Linux commands, all in one article ☞【Essentials】Bookmark! Linux basic to advanced learning roadmap 1. Using Variables 1. … Read more

Mastering String Operations in C++: A Practical Guide

Mastering String Operations in C++: A Practical Guide

Hello everyone! Today I want to share with you a super useful skill in C++: string operations. Whether it’s processing CSV files or extracting web links, once you master the basic operations of strings, these tasks can be easily accomplished! It’s like magic; let’s play with strings together! 1. Basic String Operations In C++, we … Read more