Star on GitHub ⭐ Home Install Documentation & Book Playground IDE Tutorials & Learn Standard Library & Python Interop Community & Roadmap About & Governance Engineering Blog Brand Identity Kit Direct .exe Download
Universal Standard Library

Standard Library & The Python God Call

Explore built-in zero-overhead modules for I/O, mathematical analysis, string manipulation, data structures, cryptosystems, and direct C-ABI foreign call bridging.

file.read(path) std.io

Reads the entire contents of a UTF-8 text file into a fixed stack memory buffer. Raises E008 if file not found.

set contents to file.read("config.json")
display "Loaded: ", length of contents, " bytes"
file.write(path, data) std.io

Atomically creates or overwrites target file with the specified string data. Flushes OS buffer synchronously.

call file.write with "output.txt", "Sovereign build complete"
io.read_line() std.io

Reads a single line of text from standard input (stdin) up to newline terminator with zero trailing whitespace.

display "Enter username: "
set name to io.read_line()
math.sqrt(number) std.math

Computes the IEEE-754 double precision square root using native CPU vector FPU instructions in O(1) time.

set root to math.sqrt(144) // 12.0
math.pow(base, exponent) std.math

Calculates base raised to the power exponent with double-precision accuracy across integer and fractional powers.

set val to math.pow(2, 10) // 1024
math.random(min, max) std.math

Generates a cryptographically seeded pseudo-random integer in the inclusive range [min, max].

set dice to math.random(1, 6)
string.split(text, delimiter) std.string

Partitions a string into a list of substrings separated by the specified delimiter string in O(N) linear time.

set words to string.split("enlangg is fast", " ")
string.replace(text, find, replace) std.string

Replaces all occurrences of pattern string with target string, returning a newly allocated stack string slot.

set clean to string.replace("foo-bar", "-", "_")
string.trim(text) std.string

Strips leading and trailing ASCII whitespace (spaces, tabs, newlines) without altering interior text.

set clean to string.trim(" hello world ")
list.append(list, item) std.collections

Appends an element to the end of a dynamic array list with amortized O(1) constant time allocation.

set items to []
call list.append with items, "first"
call list.append with items, "second"
map.get(map, key, default) std.collections

Retrieves value associated with key from Robin Hood hash table in O(1) average lookup time.

set user to { "name": "Ada", "role": "Engineer" }
set role to map.get(user, "role", "Guest")
http.get(url) std.network

Dispatches a non-blocking HTTPS GET request via system TLS sockets and returns status code, headers, and body.

set res to http.get("https://api.github.com/zen")
display "Response: ", res.body
http.serve(port, handler) std.network

Launches a multi-threaded POSIX/WinSock HTTP micro-daemon listening on the specified port.

listen on port 8080:
on request: respond with "Hello from Enlangg"
crypto.sha256(data) std.crypto

Generates an authentic NIST FIPS 180-4 256-bit cryptographic digest as a 64-character lowercase hexadecimal string.

set hash to crypto.sha256("sovereign_token")
crypto.hmac(key, message) std.crypto

Computes a keyed-hash message authentication code (HMAC-SHA256) for verifying data integrity and API signatures.

set signature to crypto.hmac("secret_key", "payload")
python.import(module_name) python.bridge

Loads an installed CPython package (NumPy, PyTorch, Pandas) directly into virtual memory via C-ABI foreign call bridge.

set torch to python.import("torch")
set tensor to torch.randn([3, 3])
python.eval(code_str) python.bridge

Executes arbitrary Python code within the shared virtual memory context, returning native C types back to Enlangg slots.

set result to python.eval("2 ** 32 - 1")
system.argv() std.system

Returns the full array of command line arguments passed to the executable upon process invocation.

set args to system.argv()
display "Program invoked with ", length of args, " flags"
system.time_ms() std.system

Returns current high-resolution monotonic UNIX timestamp in milliseconds since epoch (useful for precision micro-benchmarks).

set start to system.time_ms()
// run workload
set elapsed to system.time_ms() minus start
system.get_env(key) std.system

Reads the specified environment variable from the operating system session. Returns empty string if unset.

set port to system.get_env("PORT")