Tagged articles
29 articles
Page 1 of 1
Lisa Notes
Lisa Notes
Feb 27, 2026 · Fundamentals

How Python’s + Operator Concatenates Strings (and Why Numbers Fail)

The article explains that in Python the + operator joins two strings into one, demonstrates this with code examples, and warns that adding a number to a string raises a TypeError, illustrating the rule with sample output and error messages.

Arithmetic operatorsPythonString concatenation
0 likes · 3 min read
How Python’s + Operator Concatenates Strings (and Why Numbers Fail)
Code Mala Tang
Code Mala Tang
Oct 1, 2025 · Fundamentals

Why .join() Beats + for Fast String Concatenation in Python

This article compares Python's + operator and the .join() method for concatenating strings, showing how .join() offers clearer code and up to four‑times better performance by reducing memory allocations, especially when joining many strings.

Coding TipsJOINPython
0 likes · 6 min read
Why .join() Beats + for Fast String Concatenation in Python
php Courses
php Courses
Sep 24, 2025 · Backend Development

Master PHP’s implode(): Concatenate Arrays with Custom Delimiters

This article explains how PHP's implode() function joins array elements into strings, covering basic usage with delimiters, handling nested arrays, and the special case of omitting the glue argument for seamless concatenation.

ArrayBackendString concatenation
0 likes · 4 min read
Master PHP’s implode(): Concatenate Arrays with Custom Delimiters
macrozheng
macrozheng
May 23, 2025 · Fundamentals

Why ‘+’ Can Outperform StringBuilder in Java: Real Benchmarks Explained

This article investigates the performance differences between Java’s ‘+’ operator, StringBuilder, and StringJoiner for string concatenation, presenting JUnit benchmark results for single and looped concatenations, analyzing compiled bytecode, and concluding when each method is optimal for readability and speed.

JUnitString concatenationstringbuilder
0 likes · 7 min read
Why ‘+’ Can Outperform StringBuilder in Java: Real Benchmarks Explained
Python Programming Learning Circle
Python Programming Learning Circle
Dec 28, 2024 · Fundamentals

Comprehensive Guide to String Concatenation Methods in Python

This article presents a comprehensive overview of seven Python string concatenation techniques—including the plus operator, comma printing, implicit literal concatenation, percent formatting, format method, join function, f‑strings, and the multiplication operator—along with performance tips and usage recommendations.

String concatenationperformanceprogramming
0 likes · 5 min read
Comprehensive Guide to String Concatenation Methods in Python
Alibaba Cloud Developer
Alibaba Cloud Developer
Aug 29, 2024 · Fundamentals

How Java’s String Concatenation Evolved: From '+' to Hidden Classes

This article traces the evolution of Java string concatenation from the simple '+' operator through JDK 8’s StringBuilder implementation, the JDK 9+ StringConcatFactory with invokedynamic, and Alibaba’s PR 20273 that introduces hidden‑class bytecode generation, highlighting performance gains and startup‑time improvements.

JDKMethodHandlesOpenJDK
0 likes · 17 min read
How Java’s String Concatenation Evolved: From '+' to Hidden Classes
macrozheng
macrozheng
Aug 7, 2024 · Fundamentals

Why ‘+’ Can Beat StringBuilder in Java: Benchmarks and Best Practices

This article investigates the performance differences between Java’s ‘+’ operator and StringBuilder for both simple and looped string concatenations, presenting JUnit benchmark results that show ‘+’ is comparable for single concatenations but significantly slower in loops, and recommends using the appropriate method based on context.

BenchmarkJavaString concatenation
0 likes · 6 min read
Why ‘+’ Can Beat StringBuilder in Java: Benchmarks and Best Practices
Java Architect Essentials
Java Architect Essentials
Jun 16, 2024 · Backend Development

Performance Comparison of String Concatenation Using '+' Operator vs StringBuilder in Java

This article examines the performance differences between using the '+' operator and StringBuilder for string concatenation in Java, presenting JUnit benchmark tests for simple concatenations and looped concatenations, analyzing compiled bytecode, and concluding that '+' is suitable for simple cases while StringBuilder excels in loops.

JUnitJavaString concatenation
0 likes · 7 min read
Performance Comparison of String Concatenation Using '+' Operator vs StringBuilder in Java
Top Architecture Tech Stack
Top Architecture Tech Stack
Feb 5, 2024 · Fundamentals

Simple Techniques to Speed Up Python For Loops by 1.3× to 970×

This article presents a collection of straightforward Python techniques—such as list comprehensions, external length calculation, set usage, early‑exit loops, inlining functions, pre‑computations, generators, map(), memoization, NumPy vectorization, filterfalse, and join()—that can accelerate for‑loops anywhere from 1.3‑fold up to nearly a thousand‑fold, with explanations and benchmark results.

GeneratorsLoop OptimizationNumPy
0 likes · 18 min read
Simple Techniques to Speed Up Python For Loops by 1.3× to 970×
Top Architect
Top Architect
Nov 27, 2023 · Backend Development

Performance Comparison of String Concatenation Using '+' vs StringBuilder in Java

This article evaluates the execution time and bytecode differences of simple and looped string concatenation in Java, comparing the '+' operator with explicit StringBuilder usage, and concludes that '+' is fine for single concatenations while StringBuilder dramatically outperforms '+' in iterative scenarios.

JavaString concatenationperformance
0 likes · 9 min read
Performance Comparison of String Concatenation Using '+' vs StringBuilder in Java
Programmer DD
Programmer DD
Oct 26, 2021 · Backend Development

Which Java String Concatenation Method Is Fastest? A Performance Comparison

This article compares five Java string‑concatenation techniques—‘+’, String.concat(), StringUtils.join(), StringBuffer.append() and StringBuilder.append()—through extensive timing tests from 100 to 900 000 iterations, revealing their speed, memory usage and best use cases for large‑scale data processing.

Apache CommonsJavaString concatenation
0 likes · 11 min read
Which Java String Concatenation Method Is Fastest? A Performance Comparison
Python Programming Learning Circle
Python Programming Learning Circle
Mar 6, 2021 · Fundamentals

Various Ways to Concatenate Strings in Python

This article reviews eight common Python string concatenation techniques—including the + operator, commas, direct adjacency, % formatting, format(), join(), f‑strings, and the * operator—explaining their syntax, use cases, performance considerations, and recommendations for small versus large-scale concatenations.

JOINString concatenationf-string
0 likes · 3 min read
Various Ways to Concatenate Strings in Python
Architect's Tech Stack
Architect's Tech Stack
Nov 27, 2020 · Backend Development

When Does Java Use StringBuilder for String Concatenation?

This article investigates Java's string concatenation behavior, demonstrating through two examples why some concatenations invoke StringBuilder while others are optimized by the compiler, and explains the underlying bytecode differences revealed by decompiling with javap.

Compiler OptimizationJavaJavap
0 likes · 3 min read
When Does Java Use StringBuilder for String Concatenation?
Programmer DD
Programmer DD
Jul 26, 2020 · Backend Development

When Does Java Use StringBuilder for String Concatenation? A Deep Dive

This article examines why identical-looking string concatenations in Java sometimes use StringBuilder and other times are optimized away, showing bytecode differences, explaining compiler behavior, and summarizing the conditions that affect reference equality.

Compiler OptimizationJVMString concatenation
0 likes · 4 min read
When Does Java Use StringBuilder for String Concatenation? A Deep Dive
Senior Brother's Insights
Senior Brother's Insights
Apr 29, 2020 · Fundamentals

Testing += String Concatenation: JDK8 vs JDK14 Bytecode Findings

The author investigates the common advice against using the += operator for string concatenation by writing two Java programs, examining their bytecode with javap, and comparing results on Oracle JDK 8 and OpenJDK 14, revealing that JDK version and implementation affect whether a StringBuilder is automatically used.

JDKJavaString concatenation
0 likes · 5 min read
Testing += String Concatenation: JDK8 vs JDK14 Bytecode Findings
MaGe Linux Operations
MaGe Linux Operations
Apr 16, 2019 · Fundamentals

8 Powerful Ways to Concatenate Strings in Python

This article presents a comprehensive overview of eight different techniques for joining strings in Python, covering simple operators, formatting methods, built‑in functions, and best‑practice recommendations for both small and large concatenations.

JOINPythonString concatenation
0 likes · 4 min read
8 Powerful Ways to Concatenate Strings in Python
MaGe Linux Operations
MaGe Linux Operations
Feb 24, 2019 · Fundamentals

7 Efficient Ways to Concatenate Strings in Python

This article reviews seven common Python string‑concatenation techniques—including +, commas, direct literals, %, format(), join(), f‑strings, and *—and explains when each method is most suitable for small or large string assemblies.

JOINString concatenationf-string
0 likes · 4 min read
7 Efficient Ways to Concatenate Strings in Python
MaGe Linux Operations
MaGe Linux Operations
Jan 17, 2019 · Fundamentals

7 Powerful Ways to Concatenate Strings in Python

This article reviews seven common Python string concatenation techniques—including the plus operator, commas, direct literals, the % operator, format(), f-strings, join(), and the multiplication operator—highlighting their syntax, use cases, and performance considerations for both small and large strings.

JOINString concatenationf-string
0 likes · 4 min read
7 Powerful Ways to Concatenate Strings in Python
MaGe Linux Operations
MaGe Linux Operations
Jul 7, 2018 · Fundamentals

8 Powerful Ways to Concatenate Strings in Python

This guide reviews eight common Python string concatenation techniques—including the plus operator, commas, direct literals, percent formatting, format(), f-strings, join(), and the multiplication operator—highlighting their syntax, use cases, performance considerations, and recommendations for small versus large string assemblies.

JOINString concatenationf-string
0 likes · 4 min read
8 Powerful Ways to Concatenate Strings in Python