Skip to main content

Arivu (அறிவு) - Tamil Programming Language

PyPI version Python 3.7+ License: MIT

"அறிவே ஆற்றல்" (Knowledge is Power)

A dynamically-typed, interpreted programming language with easy Tamil words. Write code in your native language! Perfect for Tamil-speaking students learning programming.

🎬 Features

  • Easy Tamil Keywords: Simple Tamil words anyone can understand
  • Movie-Style Syntax: Fun and intuitive like Tamil cinema dialogues
  • Dynamic Typing: Variables can hold any type of value
  • First-Class Functions: Define and pass functions with ease
  • Recursive Functions: Full support for recursion
  • Control Flow: Simple if-else (na_sonna/illa_na_sonna/illana) and loops
  • Interactive REPL: Test code snippets interactively
  • Clean Syntax: Simple, readable, and powerful

🚀 Getting Started

Prerequisites

  • Python 3.7 or higher

Installation

Install via pip (recommended):

pip install arivu

Or install from source:

git clone https://github.com/Akash-srm861/-Arivu.git
cd -Arivu
pip install -e .

Running Programs

Run an Arivu file:

arivu examples/vanakkam.rj

Execute code directly:

arivu -c "sollu_da('Vanakkam!');"

Start the interactive REPL:

arivu

📖 Language Guide

Keywords (Easy Tamil!)

Tamil Keyword English Meaning Usage
sollu say/tell Define a function
thirupi_kudu give back Return value from function
vachuko keep/store Declare a variable
aarambam start/beginning Main program entry point
sollu_da say it! Print/output
na_sonna if I say If condition
illa_na_sonna or if I say Else if condition
illana otherwise Else
varaikkum until While loop
ellathukum for all For loop
aama yes Boolean true
illa no Boolean false
onnum_illa nothing Null value

Operators

Arithmetic: + - * / %
Comparison: == != > < >= <=
Logical: && || !

Data Types

  • Numbers: 42, 3.14
  • Strings: "Vanakkam da!"
  • Booleans: aama (yes/true), illa (no/false)
  • Null: onnum_illa (nothing)

Comments

// Single line comment

/* Multi-line
   comment */

💡 Examples

Vanakkam (Hello World)

aarambam {
    sollu_da("Vanakkam da mapla!");
    sollu_da("Nalla irukiya?");
}

Variables and Arithmetic

aarambam {
    vachuko x = 10;
    vachuko y = 20;
    vachuko sum = x + y;
    sollu_da("Sum is: ");
    sollu_da(sum);
}

Functions

sollu kuttu(a, b) {
    thirupi_kudu a + b;
}

sollu vanakkam(name) {
    sollu_da("Vanakkam, ");
    sollu_da(name);
    sollu_da("!");
}

aarambam {
    vachuko result = kuttu(5, 10);
    sollu_da(result);
    
    vanakkam("Rajini");
}

Conditionals

aarambam {
    vachuko vayasu = 25;
    
    na_sonna (vayasu >= 18) {
        sollu_da("You are an adult!");
    } illana {
        sollu_da("You are a minor!");
    }
}

With else-if:

aarambam {
    vachuko mark = 85;
    
    na_sonna (mark >= 90) {
        sollu_da("Grade: A");
    } illa_na_sonna (mark >= 80) {
        sollu_da("Grade: B");
    } illa_na_sonna (mark >= 70) {
        sollu_da("Grade: C");
    } illana {
        sollu_da("Grade: F");
    }
}

Loops

While Loop (varaikkum = until):

aarambam {
    vachuko i = 1;
    varaikkum (i <= 5) {
        sollu_da(i);
        vachuko i = i + 1;
    }
}

For Loop (ellathukum = for all):

aarambam {
    ellathukum (i = 1; i <= 5; i = i + 1) {
        sollu_da(i);
    }
}

Factorial (Recursive)

sollu factorial(n) {
    na_sonna (n <= 1) {
        thirupi_kudu 1;
    }
    thirupi_kudu n * factorial(n - 1);
}

aarambam {
    vachuko result = factorial(5);
    sollu_da("Factorial of 5 is: ");
    sollu_da(result);
}

FizzBuzz

aarambam {
    ellathukum (i = 1; i <= 30; i = i + 1) {
        vachuko div3 = i % 3;
        vachuko div5 = i % 5;
        
        na_sonna (div3 == 0 && div5 == 0) {
            sollu_da("FizzBuzz");
        } illa_na_sonna (div3 == 0) {
            sollu_da("Fizz");
        } illa_na_sonna (div5 == 0) {
            sollu_da("Buzz");
        } illana {
            sollu_da(i);
        }
    }
}

📂 Project Structure

vijay++/
├── rajini.py           # Main interpreter CLI
├── lexer.py            # Lexical analyzer (tokenizer)
├── parser.py           # Syntax analyzer (AST builder)
├── interpreter.py      # Runtime interpreter
├── LANGUAGE_SPEC.md    # Complete language specification
├── README.md           # This file
└── examples/           # Sample programs
    ├── vanakkam.rj             # Hello World in Tamil
    ├── factorial_tamil.rj      # Factorial with Tamil syntax
    ├── marks_tamil.rj          # Grading system
    ├── loops_tamil.rj          # Loop examples
    ├── calculator_tamil.rj     # Calculator
    ├── hello_world.rj          # (Old English syntax)
    ├── factorial.rj
    ├── fibonacci.rj
    ├── loops.rj
    ├── functions.rj
    ├── fizzbuzz.rj
    └── primes.rj

🎯 Built-in Functions

  • len(value) - Get length of string
  • str(value) - Convert to string
  • int(value) - Convert to integer
  • float(value) - Convert to float
  • type(value) - Get type name

🎮 Interactive REPL

Start the REPL by running python rajini.py without arguments:

$ python rajini.py

╔════════════════════════════════════════╗
║   rajini++ Interactive Shell          ║
║   'Namma style-la code potturlam!'   ║
║   Type 'exit' to quit                 ║
╚════════════════════════════════════════╝

rajini++ > vachuko x = 42;
rajini++ > sollu_da(x);
42
rajini++ > vachuko y = x * 2;
rajini++ > sollu_da(y);
84
rajini++ > exit
Vanakkam! (Goodbye!)

🎨 Philosophy

rajini++ embraces these principles:

  1. Easy Tamil words - Everyone should understand the code
  2. Movie-style fun - Programming should be enjoyable like watching a movie
  3. Simple but powerful - Easy to learn, powerful to use
  4. Namma style - Code in our own Tamil style!

🔧 Implementation Details

rajini++ is implemented in pure Python with three main components:

  1. Lexer (lexer.py) - Tokenizes source code
  2. Parser (parser.py) - Builds Abstract Syntax Tree (AST)
  3. Interpreter (interpreter.py) - Executes the AST

The language supports:

  • Lexical scoping with closures
  • Dynamic typing
  • Recursive function calls
  • Expression evaluation with proper operator precedence

📝 File Extension

rajini++ programs use the .rj file extension (short for "Rajini").

Check out the examples/ directory for sample programs:

Tamil Syntax (Easy to understand!):

  • vanakkam.rj - Hello World in Tamil
  • factorial_tamil.rj - Factorial with Tamil keywords
  • marks_tamil.rj - Grading system in Tamil
  • loops_tamil.rj - Loop demonstrations in Tamil
  • calculator_tamil.rj - Calculator with Tamil function names

Original Examples (English keywords):

  • hello_world.rj - Classic Hello World
  • factorial.rj - Recursive factorial
  • fibonacci.rj - Fibonacci sequence
  • loops.rj - Loop examples
  • functions.rj - Advanced functions
  • fizzbuzz.rj - FizzBuzz challenge
  • primes.rj - Prime number finder

Run any example:

python rajini.py examples/vanakkam.rj
python rajini.py examples/marks_tamil.rj

🚧 Future Enhancements

Potential features for future versions:

  • Arrays/Lists support
  • Dictionary/Map data structures
  • File I/O operations
  • Import/Module system
  • Exception handling
  • More built-in functions
  • Bytecode compilation for better performance

🤝 Contributing

Contributions are welcome! Feel free to:

  • Add new features
  • Improve error messages
  • Create more example programs
  • Optimize the interpreter
  • Fix bugs

📜 License

This project is open source. Use it with style!

🎬 Credits

Made for Tamil speakers who want to code in their own style! Programming should be fun and accessible to everyone.


"Namma style-la code potturlam da!"
(Let's code in our style!)

Made with ❤️ for Tamil Cinema Fans!

Metadata

Release files for arivu 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for arivu 1.0.1
File Size Uploaded Provenance
arivu-1.0.1.tar.gz 20.1 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for arivu 1.0.1
File Interpreter ABI Platform
arivu-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 35.9 kB

Release files / arivu-1.0.1.tar.gz

Download URL arivu-1.0.1.tar.gz
Size 20.1 kB
Tags Source
SHA-256 checksum
How to use checksums
5f150c042a4abb615746de61125ee5b2ec224baf0755fa1d8f4441ff137aad63
BLAKE2b-256 checksum
How to use checksums
54fc50008287533be517f8649c6a3a77990acf8e611e4cfe9fde2f9aa9ac4486
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.3

Release files / arivu-1.0.1-py3-none-any.whl

Download URL arivu-1.0.1-py3-none-any.whl
Size 15.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c0ea9f3c1b1672fe6e23fa251a952f292bdb3751c93ff0000cd3ea2c8ba71d21
BLAKE2b-256 checksum
How to use checksums
d16be640f87ab5bf1294bbaae33c414b2a974947d06a08e2dab9f4e9b7f51cb0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.3

Security for arivu 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page