# Check if at least two out of five booleans are true

**URL:** https://discourse.nodered.org/t/check-if-at-least-two-out-of-five-booleans-are-true/49596
**Category:** General
**Created:** [11 August 2021 06:24 UTC](https://discourse.nodered.org/t/check-if-at-least-two-out-of-five-booleans-are-true/49596 "2021-08-11T06:24:18Z")
**Posts on this page:** 2
**Page:** 2

<div class="post-metadata">

### Author: ![dougle03](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dougle03/32/32979_2.png) [@dougle03](https://discourse.nodered.org/u/dougle03)
#### Post date: [17 August 2021 09:10 UTC](https://discourse.nodered.org/t/check-if-at-least-two-out-of-five-booleans-are-true/49596/21 "2021-08-17T09:10:11Z")

</div>

And a fourth might be to have separate flows polling the relays and storing their values in variables, then a flow to retrieve the values, sum them, then function to determine the output state yes|no.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [16 October 2021 09:10 UTC](https://discourse.nodered.org/t/check-if-at-least-two-out-of-five-booleans-are-true/49596/22 "2021-10-16T09:10:17Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.

[Previous page](https://discourse.nodered.org/t/check-if-at-least-two-out-of-five-booleans-are-true/49596.md?page=1)
