HexLibraryHexLibrary
</> HexCodeSign inSign up
PythonJavaScriptTypeScriptCC++JavaPHPGoRustRubyBashSQLLuaPerlCOBOLPascalDelphiFortranDartSwiftC#JuliaGroovyRElixirHaskellKotlinScalaClassic ASPClipperMS-DOS
LESSONS
Introduction to Python: Print and RepeatVariablesData Types & NumbersStringsListsConditions (if / elif / else)Loops (for / while)FunctionsOperatorsDictionariesTuples & SetsError Handling (try / except)Classes (Object-Oriented)File OperationsComments & IndentationBooleans (True / False)Lambda & map / filterModules (import)InheritanceVariable Scope
REFERENCE
📖 Overview
🖥️ Output & Input
🔢 Numbers & Math
✍️ String
📋 List
🗂️ Dictionary & Set
🔁 Condition & Loop
🧩 Function
📁 File & Error
🔄 Type & Conversion
Python›REFERENCE

Python — Command Reference

Python's most-used commands, built-in functions and methods — each with its syntax, an explanation, a runnable example and its real-world use. Pick a category, click a command, and try the example yourself.

9 categories · 45 commands

🖥️

Output & Input

Printing to the screen and taking input from the user.

print()input()f-string
3 commands →
🔢

Numbers & Math

Numeric operations, rounding and math functions.

abs()round()min() / max()sum()+2
6 commands →
✍️

String

Methods for changing, searching, splitting and formatting strings.

len()upper() / lower()strip()replace()+4
8 commands →
📋

List

Working with ordered, mutable collections of data.

items []append()insert()remove() / pop()+3
7 commands →
🗂️

Dictionary & Set

Key-value mappings (dict) and unique collections (set).

dictionary {}get()keys() / values() / items()set
4 commands →
🔁

Condition & Loop

Decision-making (if) and repetition (for/while) structures.

if / elif / elseforrange()enumerate()+2
6 commands →
🧩

Function

Defining and reusing your own commands.

def / returndefault parameter*args / **kwargslambda
4 commands →
📁

File & Error

Reading/writing files and catching errors.

open() / withtry / exceptraise
3 commands →
🔄

Type & Conversion

Converting between data types and type checking.

int() / float()str()type() / isinstance()bool() / True-False
4 commands →
HexLibraryHexLibrary

Learn programming more clearly. Every command is explained line by line with colors, reinforced with runnable exercises, test your code instantly — all in one place, free.

Learn

  • Home
  • Languages & Lessons
  • HexCode

Company

  • About
  • Contact

Legal

  • Privacy Policy
  • Terms of Use

Other Projects

  • HexToolz
  • Free Service Manuals
© 2026 HexLibrary · The clearest way to learn code