История страницы
">="
...
Greater than or equal to Version 5 (Java)
Группа действийAction group: ОператорыOperators
...
Description
Возвращает True, если первый операнд больше второго или равен ему. Иначе False.
Иконка
Параметры действия
Входные параметры:
Поле "Операнд 1" - Выражение, имеющее результат числового типа или числовая переменная.
Поле "Операнд 2" - Выражение, имеющее результат числового типа или числовая переменная.
Выходные параметры:
Результат - Логическая переменная, содержащая результат выполнения действия
Настройки
...
Свойство
...
Англ. наименование
...
Описание
...
Тип
...
Пример заполнения
...
Обязательность заполнения поля
...
Параметры
...
Returns True if the first operand is greater than or equal to the second operand. Otherwise False.
Action icon
Settings of parameters
Property | Description | Type | Filling example | Mandatory field |
Parameters | ||||
First operand | Value or variable of the first opreand | Robin.Numeric | Yes | |
Second operand | Value or variable of the second opreand | Robin.Numeric | Yes | |
Results | ||||
Result | The result of the comparison, true if the first number is greater or equals to the other, false otherwise. | Robin.Boolean | true |
Special conditions of use
None.
Example of use
Task
There is "Variable1" with value = 17 and "Variable2" with value = 3. It is required to check the expression Variable1>=Variable2. If the result is positive, output a dialog box with a message - true, if the result is negative, output a dialog box with a message - false.
Solution
Use the actions
Особые условия использования
Отсутствуют.
Пример использования
Задача
Существует "Variable1" со значением = 17 и "Variable2" со значением = 3. Требуется проверить выражение Variable1>=Variable2. При положительном результате вывести диалоговое окно с сообщением - верно, при отрицательном результате с сообщением - неверно.
Решение
Воспользоваться действиями "Greater than or equal to", "If", "Show message".
...
Implementation
- Создать схемуAssemble a robot scheme consisting of actions:
Создать переменную с типом логический "Variable3" для записи в нее результата действия - Create a variable with the boolean type "Variable3" to record the result of the "Greater than or equal to" action into it.
- Перетащить действие Move the "Greater than or equal to" на рабочую область и настроить его параметрыaction to the workspace and set its parameters.
Перетащить действие - Move the "If" на рабочую область и указать в параметре действия action to the workspace and set the action parameter to "Variable3".
- В ветвь In the "True" добавить действие branch, add the "Show message" и настроить его параметрыaction and set its parameters.
В ветвь - In the "False" добавить действие branch, add the "Show message" и настроить его параметрыaction and set its parameters.
- Запустить робота по кнопке "Запуск" и верхней панелиLaunch the robot using the "Start" button and the top panel.
Результат
Result
The comparison of variable values has been performed successfully, the dialog box with the result is displayed Сравнение значений переменных выполнено успешно, отображено диалоговое окно с результатом