GenZLang is a fun and modern twist on programming language design, integrating Gen Z slang to make coding more relatable and engaging for younger developers. Built using Flex, this project focuses on the development of a lexical analyzer that tokenizes Gen Z-styled code into syntactically correct tokens for further compilation stages.
To develop a lexical analyzer for a custom Gen Z-inspired programming language using Flex, replacing traditional keywords and operators with Gen Z terms and cultural references.
- โ Recognizes Gen Z slang as language keywords, functions, and operators
- โ Supports arithmetic, relational, logical, and assignment operators
- โ Handles identifiers, numbers, strings, and comments
- โ Detects library includes
- โ Allows for dynamic function detection
yeet, big_numbers, lowkey, drip, noCap, slide, orNah, rizz
>=, <=, ==, >, <
+, -, *, /, %, ++, --
=, +=, -=, *=, /=, %=
&& โ bet
|| โ eitherOrNah
! โ sike
- Integers:
123 - Floats:
123.456 - Negatives:
-10
- Variable/Function names like:
glowUp, drip_level
| Zigma boi be like | Meaning |
|---|---|
yapp() |
print() |
yoink() |
scanf() |
master_chief() |
main() |
Any identifier followed by ( is recognized as a function |
"fortnite", "big justice!"
-
Single-line:
// This is a comment -
Multi-line:
/* This is a multi-line comment */
#include <zoomer.h>- Flex (Fast Lexical Analyzer Generator)
- Gen Z cultural references โจ
Coming soon โ setup instructions, example code, and how to compile using flex and gcc.
#include <zoomer.h>
master_chief() {
drip_level = 100;
yapp("Rizz mode activated!");
}