Tagged articles

String Formatting

21 articles · Page 1 of 1
Lisa Notes
Lisa Notes
Jun 25, 2026 · Fundamentals

Java Basics: Numbers, Characters, and String Handling – Day 53 Learning Notes

This tutorial walks through Java's core numeric and character utilities, covering number wrapper classes and autoboxing/unboxing, the Number hierarchy, formatted output with printf/format, DecimalFormat patterns, and the Math class’s constants and methods for arithmetic, logarithmic, trigonometric, and random number generation, all illustrated with concrete code examples.

DecimalFormatJavaMath
0 likes · 15 min read
Java Basics: Numbers, Characters, and String Handling – Day 53 Learning Notes
Lisa Notes
Lisa Notes
Mar 29, 2026 · Fundamentals

Python String Formatting: % Placeholders vs f‑Strings Explained

This tutorial walks through Python's two main string formatting techniques—classic % placeholders and modern f‑strings—detailing specifiers like %d, %f, %s, %.2f, and providing concrete code examples that show how each method formats name, age, and salary variables.

PythonString Formattingf-strings
0 likes · 3 min read
Python String Formatting: % Placeholders vs f‑Strings Explained
Code Mala Tang
Code Mala Tang
Sep 24, 2025 · Fundamentals

5 Powerful Ways to Use Python’s print() Function

Discover five versatile techniques for Python’s print()—from simple string concatenation and comma separation to modern f‑strings, percent formatting, and the .format() method—complete with clear examples and guidance on when to use each approach for clean, readable output.

Code examplesString Formattingf-strings
0 likes · 5 min read
5 Powerful Ways to Use Python’s print() Function
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Mar 4, 2025 · Fundamentals

Master Java String Formatting: 9 Practical Techniques with Code Samples

This article introduces a continuously updated Spring Boot 3 case collection and provides a step‑by‑step guide to nine Java string‑formatting methods—including String.format, MessageFormat, text blocks, number grouping, rounding, zero‑padding, printf, whitespace, and concatenation—complete with runnable code examples.

JavaMessageFormatString Formatting
0 likes · 6 min read
Master Java String Formatting: 9 Practical Techniques with Code Samples
Code Mala Tang
Code Mala Tang
Jan 31, 2025 · Fundamentals

Master Python String Formatting: From % Operator to f-Strings

This article explores Python's string formatting techniques—from the classic % operator and the flexible .format() method to modern f-strings—detailing their syntax, advantages, disadvantages, and additional tools like format_map, Template, and zfill, helping developers choose the most readable and efficient approach.

String Formattingf-stringsformat method
0 likes · 7 min read
Master Python String Formatting: From % Operator to f-Strings
Python Programming Learning Circle
Python Programming Learning Circle
Dec 30, 2023 · Fundamentals

10 Useful Python Tips and Tricks for Beginners

This article presents ten practical Python tips and tricks, covering list comprehensions, efficient list traversal, element swapping, list initialization, string construction, tuple returns, dictionary access, library usage, slicing and stepping, and indentation best practices, each illustrated with clear code examples.

PythonString FormattingTips
0 likes · 10 min read
10 Useful Python Tips and Tricks for Beginners
Test Development Learning Exchange
Test Development Learning Exchange
Nov 26, 2023 · Fundamentals

Using the % Placeholder for String Formatting in Python

This article explains Python's % placeholder for string formatting, covering basic specifiers, multiple value substitution using tuples, dictionaries, and f-strings, and advanced formatting options like width, padding, and precision, accompanied by clear code examples.

String Formattingpercent operatorplaceholder
0 likes · 5 min read
Using the % Placeholder for String Formatting in Python
FunTester
FunTester
Dec 1, 2020 · Fundamentals

Python String Formatting: % Operator and format() Method

This article explains Python's two string‑formatting approaches—the C‑style % operator and the more powerful format() method—covering integer, float, and string placeholders, alignment, precision, and advanced usage with clear code examples.

Programming FundamentalsPythonString Formatting
0 likes · 6 min read
Python String Formatting: % Operator and format() Method
Programmer DD
Programmer DD
Mar 20, 2020 · Fundamentals

Mastering YAML Multi‑Line Strings: Preserve Paragraphs or Flatten Text

This guide explains how to write multi‑line text in YAML configuration files, covering techniques to keep paragraph breaks when displaying the value and methods to collapse line breaks for a single‑line output, complete with code examples and practical differences.

DevOpsMultiline StringsString Formatting
0 likes · 5 min read
Mastering YAML Multi‑Line Strings: Preserve Paragraphs or Flatten Text
Test Development Learning Exchange
Test Development Learning Exchange
Aug 17, 2018 · Fundamentals

Using Python's str.format() for Advanced String Formatting

This article explains Python's str.format() method introduced in Python 2.6, covering its basic syntax, positional and named arguments, object formatting, numeric formatting options, alignment, fill characters, type specifiers, brace escaping, and custom template usage with clear code examples.

String Formattingcode exampleformat-specifiers
0 likes · 4 min read
Using Python's str.format() for Advanced String Formatting
MaGe Linux Operations
MaGe Linux Operations
Feb 25, 2018 · Fundamentals

10 Essential Python Tricks Every Beginner Should Know

This guide presents ten practical Python techniques—from list comprehensions and efficient looping to elegant swapping, list initialization, string formatting, multiple returns, dictionary access, using Counter, slicing, and consistent indentation—helping new programmers write cleaner, more Pythonic code.

Code stylePythonString Formatting
0 likes · 9 min read
10 Essential Python Tricks Every Beginner Should Know