# Reaction time experiment

**URL:** <https://discourse.processing.org/t/reaction-time-experiment/19813>\
**Category:** Coding Questions\
**Created:** [April 15, 2020, 7:01pm UTC](https://discourse.processing.org/t/reaction-time-experiment/19813 "2020-04-15T19:01:13Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [April 15, 2020, 10:09pm UTC](https://discourse.processing.org/t/reaction-time-experiment/19813/4 "2020-04-15T22:09:57Z")

</div>

> [@14mmss](#):
>
> if (s == seconds) { if (m == miliseconds)

This condition may not ever be met because millis() is quietly updating in the background and you are only checking it every draw cycle which is 1/60 of a sec (default framerate is 60 fps).

The chance that they are exactly == at the instance you check is not likely.

Other options are \>, \<, \>=, \<=, != …

Pick one that makes sense and try it.

Reference:

> **[Equality, Relational, and Conditional Operators (The Java™ Tutorials \> ...](https://docs.oracle.com/javase/tutorial/java/nutsandbolts/op2.html)**
>
> This beginner Java tutorial describes fundamentals of programming in the Java programming language

`:)`

---

_[View the full topic](https://discourse.processing.org/t/reaction-time-experiment/19813)._
