semvec/pypi-packages huggingface dataset:
wibor-simulation 0.1.0
Simulates the loan installments at different interest rates.
License: MIT
Requires Python: >=3.6.1,<4.0

# wibor-simulation


<p align="center">
<a href="https://pypi.python.org/pypi/wibor-simulation">
    <img src="https://img.shields.io/pypi/v/wibor-simulation.svg"
        alt = "Release Status">
</a>

<a href="https://github.com/PhillCli/wibor-simulation/actions">
    <img src="https://github.com/PhillCli/wibor-simulation/actions/workflows/main.yml/badge.svg?branch=release" alt="CI Status">
</a>

<a href="https://wibor-simulation.readthedocs.io/en/latest/?badge=latest">
    <img src="https://readthedocs.org/projects/wibor-simulation/badge/?version=latest" alt="Documentation Status">
</a>

<a href="https://pyup.io/repos/github/PhillCli/wibor-simulation/">
<img src="https://pyup.io/repos/github/PhillCli/wibor-simulation/shield.svg" alt="Updates">
</a>

</p>


Simulates the loan installments at different interest rates


* Free software: MIT
* Documentation: <https://wibor-simulation.readthedocs.io>


## Features

* simulations of loan installment based on changing interest rate (WIBOR6M)

    ```shell
    wibor-simulation simulation 100000.00 0.05 60 0.0025,0.0175,0.0270,0.0500,0.069
    ```


## Credits

This package was created with [Cookiecutter](https://github.com/audreyr/cookiecutter) and the [zillionare/cookiecutter-pypackage](https://github.com/zillionare/cookiecutter-pypackage) project template.
pyas 1.2.4
Run machine code, assembly and webassembly directly in Python
License: MIT

# pyas

Run machine code, assembly and webassembly directly in Python.

Have you ever realized you can't remember how to add numbers in Python but you **do** remember how to do it in assembly?

If the answer is yes this is the package for you, using `pyas` you will be able to run machine code, assembly and webassembly directly from within Python!

```diff
- currently this only supports Linux
```

## Installation

### From PyPI

```sh
pip3 install pyas
```

### From GitHub

```sh
pip3 install git+https://github.com/donno2048/pyas
```

## Usage / Example

### Machine code

Comments are noted with `;`, `#` and `//`

```py
from pyas import function
add_one = function(
    '8b c7'  # mov eax, edi
    '83 c0 01'  # add eax, 1
    'c3'  # ret
)
return_same = function(
    '''
    8b c7  # mov eax, edi
    c3  // ret
    '''
)

print(add_one(10), "=", return_same(10), "+ 1")
# output: 11 = 10 + 1

add_numbers = lambda i, val: function(
    '''
    8b c7  ; mov eax, edi
    83 c0 %.2x # add eax, i
    c3  // ret
    '''
    %i,
    val # every value after the first argument will be passed directly to the function if supplied
)

print(add_numbers(4, 10), "=", "10 + 4")
# output: 14 = 10 + 4

```

### Assembly

```py
from pyas import function
add_one = function(
    '''
    mov eax, edi
    add eax, 1
    ret
    ''',
    raw = False
)
return_same = function(
    '''
    mov eax, edi
    ret
    ''',
    raw = False
)

print(add_one(10), "=", return_same(10), "+ 1")
# output: 11 = 10 + 1

add_numbers = lambda i, val: function(
    '''
    mov eax, edi
    add eax, %d
    ret
    '''
    %i,
    val, # every value after the first argument will be passed directly to the function if supplied
    raw = False
)

print(add_numbers(4, 10), "=", "10 + 4")
# output: 14 = 10 + 4

```

## WebAssembly

pyas will automatically recognize running in a web browser and will run Webassembly, but you'll have to specify a `func_name`.

```py
from pyas import function
add_one = function(
    '\0asm\1\0\0\0\1\6\1`\1'
    '\x7f\1\x7f\3\2\1\0\7'
    '\x0b\1\7add_one\0\0\n\t'
    '\1\7\0\x20\0A\x01j\x0b'
    , func_name = 'add_one')
print(f"{add_one(10)} = {add_one(9)} + 1")
```

View [online](https://donno2048.github.io/pyas/)