Does this code is logic
bestime = 0.0004
timeneed = 0.02 // 3000tr/min
elapsedTime = timeneed
elapsedTime = bestime
Does this code is logic
bestime = 0.0004
timeneed = 0.02 // 3000tr/min
elapsedTime = timeneed
elapsedTime = bestime
Really?
You have started a few topics now, the last one I answered you did not respond to anyone. Now this question is as pointless as tits on a bull.
I'll ask one too, why do dogs have cold noses?
does it works or no?
Yes if its pseudo code.
No if its real code.
can you explain more
The code which is extremely sparse will work if:
However the assignments to elapsedTime overwrite each other, timeneed is effectively not used and elapsedTime == bestime, which is the same as just writing:
elapsedTime = 0.0004;
Asking if code will work is a totally pointless thing to do: type it in and test it.
Only time I wouldn't do that is if a failure would be catastrophic, like accidentally setting off a nuclear weapon. But then I'd test it with an LED I suppose, or have it play a recording of a bomb.
Also, before you post, preview your typing to see if the tags actually worked.