Operations#
Operations are the fundamentals when checking for conditions. They are the building blocks of all programming languages.
== is equals
!= is not equals
<= less than or equal to
>= greater than or equal to
> greater than
< less than
You can also use these operations in conjunction with && (and) and || (or) to check for multiple conditions.
For example, if you wanted to check if a variable was greater than 5 and less than 10, you would use the following code:
if (variable > 5 && variable < 10) {
// Do something
}
In this way, you can create complex conditions and make your robot function much better.