Enjoy an ad free experience by logging in. Not a member yet? Register.
|
|
Results 1 to 2 of 2
-
04-05-2016, 03:55 AM #1New to the CF scene
- Join Date
- Apr 2016
- Posts
- 1
- Thanks
- 0
- Thanked 0 Times in 0 Posts
Keeping track of calls to a function?
I'm a beginner to js and currently a little lost. Just wondering if someone can give me an example as to how I can track the number of calls to a function.
I'm trying to track how many time units a state lasts for.
The goal is to track of the number of immediately matching on*off states for prior images, so that when the state changes you can tell how many time units (calls to your function) that state lasted for, and hence which of the following states it was:
a. On for 1–2 time units = Dot
b. On for ≥ 3 time units = Dash
c. Off for 1–2 time units = Inter*element space
Any examples like this out there?
Greatly appreciated
-
04-05-2016, 04:43 PM #2Master Coder
- Join Date
- Jan 2011
- Location
- Washington
- Posts
- 6,251
- Thanks
- 30
- Thanked 859 Times in 857 Posts
Here's a nice article on timing events: https://blog.mariusschulz.com/2013/1...th-consoletime
Evolution - The non-random survival of random variants.
Physics is actually atoms trying to understand themselves.



Reply With Quote
