Skip to content

SnowDev9099/Loom-lightweight-framework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 

Repository files navigation

Loom Language

Introduction

Welcome to Loom, a lightweight and intuitive programming language designed for simplicity and versatility. Loom offers a rich set of features to support various programming tasks, from basic arithmetic operations to advanced functionalities like function definitions and logging. This comprehensive documentation will guide you through the language syntax and its capabilities.

Features Overview

Let's dive into the key features of the Loom language:

Arithmetic Operations

Loom supports standard arithmetic operations, allowing you to perform calculations effortlessly.

Example:

result = 5 + 3 result = 10 - 2 result = 6 * 4 result = 20 / 5

Function Definitions

Define custom functions to encapsulate reusable blocks of code, enhancing code organization and modularity.

Example:

function add(a, b) = ( return a + b )

Loops

Execute code blocks repeatedly using loop constructs, facilitating iterative processes and tasks.

Example:

loop(5) ( debug.system.log("Loop iteration") )

Placeholders

Dynamically substitute values into expressions with placeholders, offering flexibility and dynamic behavior in your code.

Example:

result = add(placeholder(), 5)

Logging

Print messages of different types (log, warning, or error) for debugging purposes, aiding in code troubleshooting and development.

Example:

debug.system.log.log("This is a log message") debug.system.log.warning("This is a warning message") debug.system.log.error("This is an error message")

Getting Started

Ready to start using Loom?

Follow these steps:

Clone the repository to your local machine. Install the interpreter. Write Loom scripts using your favorite text editor. Execute your scripts using the interpreter. Explore and experiment with Loom's features to build amazing projects! Conclusion Loom provides a simple yet powerful programming environment suitable for various tasks, from scripting to application development. Its intuitive syntax, rich feature set, and ease of use make it an excellent choice for developers looking to write clean, expressive, and efficient code. Get started with Loom today and unlock your programming potential!

Running the code!

make sure the file has the .loom file extension

and save the code.

then in your, terminal, idle or any other python code runner type the following python loomloom.py this runs the libary but to run scripts you need to do python loomloom.py ReplaceThisWithYourScriptName.loom

Alternative way of writing code!

Ready to start using Loom? Follow these steps:

Clone the repository to your local machine. click code, then codespaces, then create codespace. go into loomloom.py and scroll down until you see

loom_code = """

debug.system.log("Starting Loom code execution")

"""

in between the """ at the top and bottom is where you can code.

Explore and experiment with Loom's features to build amazing projects! Conclusion Loom provides a simple yet powerful programming environment suitable for various tasks, from scripting to application development. Its intuitive syntax, rich feature set, and ease of use make it an excellent choice for developers looking to write clean, expressive, and efficient code. Get started with Loom today and unlock your programming potential!

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published