Tag

Example

0 views collected around this technical thread.

Java Captain
Java Captain
May 21, 2025 · Fundamentals

Understanding Java Thread States and Their Transitions with Example Code

This article explains the six Java thread states defined in java.lang.Thread.State, describes the meaning of each state, illustrates the possible state transitions, and provides three runnable code examples that demonstrate NEW, RUNNABLE, BLOCKED, WAITING, TIMED_WAITING and TERMINATED states along with their console outputs.

ExampleJavaThread
0 likes · 11 min read
Understanding Java Thread States and Their Transitions with Example Code
Test Development Learning Exchange
Test Development Learning Exchange
Feb 28, 2025 · Fundamentals

Understanding Python Sets: Definition, Operations, and Practical Examples

This article introduces Python's set data structure, explains its unordered, unique, and mutable characteristics, demonstrates how to create sets, and provides eleven practical code examples covering basic definitions, element addition and removal, set operations like union, intersection, difference, subset checks, deduplication, iteration, and conditional filtering.

Data StructuresExamplePython
0 likes · 7 min read
Understanding Python Sets: Definition, Operations, and Practical Examples
Test Development Learning Exchange
Test Development Learning Exchange
Feb 26, 2025 · Fundamentals

Understanding Python Tuples: Definition, Features, and Practical Examples

This article introduces Python tuples, explaining their immutable ordered nature, core characteristics, and provides eleven practical code examples ranging from basic definition and indexing to unpacking, concatenation, using tuples as dictionary keys, and converting them to lists, illustrating common use cases and best practices.

Data StructureExampleImmutable
0 likes · 8 min read
Understanding Python Tuples: Definition, Features, and Practical Examples
Deepin Linux
Deepin Linux
Jan 8, 2025 · Fundamentals

Deep Dive into C++20 Coroutines: Principles, Components, and Practical Applications

This article explains the fundamentals of C++20 coroutines, describing their lightweight asynchronous execution model, key language constructs such as co_await, co_yield, and co_return, the underlying components like promise objects and coroutine handles, and demonstrates real‑world usage through comprehensive code examples for networking, file I/O, generators, and task scheduling.

Asynchronous ProgrammingC++20Coroutines
0 likes · 32 min read
Deep Dive into C++20 Coroutines: Principles, Components, and Practical Applications
Go Programming World
Go Programming World
Dec 30, 2024 · Backend Development

Understanding and Using sync.Cond in Go: Source Code Analysis and Practical Examples

This article explains the purpose, internal implementation, and correct usage patterns of Go's sync.Cond concurrency primitive, walks through its source code, demonstrates simple and advanced examples—including a custom concurrent waiting queue—and provides test cases to illustrate its behavior in real-world scenarios.

Condition VariableExampleQueue
0 likes · 20 min read
Understanding and Using sync.Cond in Go: Source Code Analysis and Practical Examples
php中文网 Courses
php中文网 Courses
Jul 9, 2024 · Backend Development

Understanding the Boolean true in PHP and Its Common Uses

This article explains the PHP boolean true, its role in conditionals and function return values, and demonstrates common usage through examples such as simple if statements, file writing with file_put_contents, and boolean variable assignments, illustrating how true indicates successful operations.

BooleanConditionalsExample
0 likes · 3 min read
Understanding the Boolean true in PHP and Its Common Uses
Architecture Development Notes
Architecture Development Notes
Jul 5, 2024 · Artificial Intelligence

Simplify Multi‑LLM Integration in Rust with the genai Library

genai is a Rust library that unifies the APIs of major large language models, offering a lightweight, native solution with simple chat‑focused examples, demonstrated through a dual‑model Rust program, and outlines future expansions such as additional model support, multimodal capabilities, and performance optimizations.

APIArtificial IntelligenceExample
0 likes · 6 min read
Simplify Multi‑LLM Integration in Rust with the genai Library
php中文网 Courses
php中文网 Courses
May 20, 2024 · Backend Development

Using curl_init() in PHP: Syntax, Parameters, Return Value, and Example

This article explains the PHP curl_init() function, covering its syntax, optional URL parameter, return value, and provides a detailed example demonstrating how to initialize a cURL session, set options, execute the request, handle errors, and process the response data.

APIBackend DevelopmentExample
0 likes · 4 min read
Using curl_init() in PHP: Syntax, Parameters, Return Value, and Example
php中文网 Courses
php中文网 Courses
Jan 18, 2024 · Backend Development

Using PHP str_word_count() Function to Count Words in a String

This article explains the PHP str_word_count() function, detailing its syntax, parameters, and multiple code examples that demonstrate counting words, retrieving word lists, obtaining word positions, customizing ignored characters, and using regular expressions for word matching.

ExamplePHPbackend
0 likes · 4 min read
Using PHP str_word_count() Function to Count Words in a String
php中文网 Courses
php中文网 Courses
Jul 11, 2023 · Backend Development

PHP trim() Function: Description, Syntax, Parameters, Return Value, and Examples

This article explains PHP's built-in trim() function, covering its purpose, related ltrim() and rtrim() functions, syntax, parameters, default character list, return value, and provides two practical code examples along with links to further learning resources.

ExamplePHPTRIM
0 likes · 3 min read
PHP trim() Function: Description, Syntax, Parameters, Return Value, and Examples
IT Architects Alliance
IT Architects Alliance
Aug 21, 2022 · Fundamentals

Understanding Java Serialization, Deserialization, and serialVersionUID

This article explains Java object serialization and deserialization, why implementing Serializable and defining a serialVersionUID are necessary for persistence and network transfer, and demonstrates the impact of transient and static fields with complete code examples.

ExampleJavaSerialization
0 likes · 10 min read
Understanding Java Serialization, Deserialization, and serialVersionUID
Python Programming Learning Circle
Python Programming Learning Circle
Mar 12, 2022 · Fundamentals

Python Movie Ticket Booking System: Code Walkthrough and Implementation

This article presents a step‑by‑step Python tutorial for building a console‑based movie ticket reservation system, covering data structures for film information, seat‑booking logic, film selection, and a controller that integrates all components into a functional application.

ExampleOOPconsole-app
0 likes · 11 min read
Python Movie Ticket Booking System: Code Walkthrough and Implementation
Python Programming Learning Circle
Python Programming Learning Circle
Nov 6, 2021 · Fundamentals

Understanding Python's pickle Module: Functions, Usage, and Examples

This article introduces Python's built-in pickle module, explains its four core functions (dumps, loads, dump, load), details their parameters and usage, and provides code examples for serializing and deserializing objects to memory and files, while noting performance limitations and alternatives such as ZODB.

Data PersistenceExamplePickle
0 likes · 8 min read
Understanding Python's pickle Module: Functions, Usage, and Examples
Laravel Tech Community
Laravel Tech Community
Aug 26, 2021 · Backend Development

PHP imagefilledpolygon Function: Drawing and Filling Polygons

This article explains the PHP imagefilledpolygon function, detailing its parameters, return values, and providing a complete example that creates an image, allocates colors, defines polygon points, draws a filled polygon, outputs the PNG, and cleans up the resources.

ExampleImagePHP
0 likes · 3 min read
PHP imagefilledpolygon Function: Drawing and Filling Polygons
Laravel Tech Community
Laravel Tech Community
Jul 20, 2021 · Backend Development

Using getimagesizefromstring to Retrieve Image Dimensions from a String in PHP

getimagesizefromstring is a PHP function that extracts an image’s width and height from raw image data supplied as a string, mirroring getimagesize but accepting string input; the article explains its parameters, return values, and provides example code comparing file‑based and string‑based usage.

ExamplePHPbackend
0 likes · 2 min read
Using getimagesizefromstring to Retrieve Image Dimensions from a String in PHP
Laravel Tech Community
Laravel Tech Community
Jul 13, 2021 · Backend Development

PHP dir() Function – Returns a Directory Instance

The article explains PHP's dir() function, detailing its parameters, return values, and providing a complete example that demonstrates opening a directory, retrieving its handle and path, iterating over entries, and closing the directory resource.

Examplebackenddir
0 likes · 2 min read
PHP dir() Function – Returns a Directory Instance
Laravel Tech Community
Laravel Tech Community
Jul 6, 2021 · Backend Development

PHP cal_days_in_month Function: Returns Number of Days in a Month for a Given Calendar

The article explains PHP's cal_days_in_month function, detailing its purpose, parameters (calendar, month, year), return value, and provides a complete example showing how to retrieve and display the number of days in a specific month of a given year.

DateExamplecalendar
0 likes · 2 min read
PHP cal_days_in_month Function: Returns Number of Days in a Month for a Given Calendar
Laravel Tech Community
Laravel Tech Community
Jun 19, 2021 · Backend Development

PHP cal_from_jd Function: Convert Julian Day to a Supported Calendar

This article explains the PHP cal_from_jd() function, which converts a given Julian Day number into a date according to a specified calendar such as Gregorian, Julian, Jewish, or French, detailing its parameters, return structure, and providing a complete usage example.

Exampledate-conversionjulian-day
0 likes · 2 min read
PHP cal_from_jd Function: Convert Julian Day to a Supported Calendar
Laravel Tech Community
Laravel Tech Community
Jun 6, 2021 · Backend Development

PDO::getAttribute – Retrieve a Database Connection Attribute

The article explains the PDO::getAttribute method, lists all PDO::ATTR_* constants that can be queried, describes its return behavior, and provides a PHP example demonstrating how to retrieve multiple connection attributes for debugging.

ExamplePDOPHP
0 likes · 2 min read
PDO::getAttribute – Retrieve a Database Connection Attribute