# Evaluating Code

This module implements the `evaluate()` function for usage in your applications. Please note that this UNSAFE function can be a security risk if not used properly. Please use it with caution. It's powerful but can be nasty if misused.

```
# For Operating Systems using our Quick Installer.
install-bx-module bx-unsafe-evaluate

# Using CommandBox to install for web servers.
box install bx-unsafe-evaluate
```

{% hint style="danger" %}
DISCOURAGED

We have provided this function for those who need to evaluate dynamic code in their applications OR fore legacy apps still using it. This function is not for general usage and should be used with caution.
{% endhint %}

* `evaluate( expression )`: Evalutes the expression dynamically from left to right and returns the reuslt of the rightmost expression.

```java
name = "boxlang"
lastName = "majano"
op = "eq"

println( evaluate( "#first# #op# #second#" ) )
```

### GitHub Repository and Reporting Issues <a href="#github-repository-and-reporting-issues" id="github-repository-and-reporting-issues"></a>

Visit the [GitHub repository](https://github.com/ortus-boxlang/bx-unsafe-evaluate) for release notes. You can also file a bug report or improvement suggestion via [Jira](https://ortussolutions.atlassian.net/secure/CreateIssueDetails!init.jspa?pid=13359\&components=27028\&issuetype=1).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://boxlang.ortusbooks.com/boxlang-framework/modularity/evaluating-code.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
