Ecosystem
Function & Script Library
Explore and run open-source algorithms, mathematical routines, and propositional logic models directly in your browser.
Algorithms
Safe FizzBuzz Algorithm
Classic interview problem using AniKode range loops with zero risk of infinite freezing.
~ Safe Range Loop FizzBuzz in AniKode ~
loop i from 1 to 20 {
if (i % 15 == 0) {
say.out("FizzBuzz")
} else if (i % 3 == 0) {
By Anikesh
#loops#math
Logic
Propositional Logic Security Auditor
Verify access control policies using first-class logic operators (implies, iff, all, any).
~ Propositional Logic Access Rules ~
fn verifyAccess(isAdmin, isManager, is2FA, score) {
\ Rule 1: Admin implies 2FA is active \
let rule1 = isAdmin implies is2FA
By Anikesh
#logic#security
Algorithms
Binary Search Function
Fast O(log n) element lookup using recursion and the recurse() keyword.
~ Recursive Binary Search in AniKode ~
fn binarySearch(arr, target, low, high) {
if low > high {
return -1
}
By Anikesh
#search#recursion
Utilities
Polymorphic String & List Utilities
Manipulate strings, reverse sequences, and check memberships polymorphically.
~ Polymorphic Methods in AniKode ~
set word = " AniKode Language "
say.out("Original:", word)
say.out("Trimmed:", word.trim())
say.out("Upper:", word.trim().upper())
By Anikesh
#strings#lists
Math
Statistical Aggregator (Mean & Clamp)
Calculate average and clamp scores using built-in math namespace.
~ Statistical Aggregator ~
fn calculateStats(scores) {
let total = 0
each s in scores {
set total = total + s
By Anikesh
#math#statistics
Games
Number Guessing Mini Game
Simple interactive game using random generation and conditionals.
~ Number Guessing Game ~
let secret = math.floor(math.random() * 50) + 1
say.out("I'm thinking of a number between 1 and 50.")
say.out("(For test demo, secret is:", secret, ")")
By Anikesh
#game#interactive