in line 19 why we pushed curday
i am not getting exactly
what actually we are passing into stack
Stock problem doubt
Hello @yatin,
Observe the follwing picture:
We are comparing the price of current day with the price at previous day.
So, when you pushed curday in line 19.
You are actually pushing the previous day for the next iteration.
This is done to make the above mentioned comparisons.
Hope, this would help.
Give a like, if you are satisfied.
1 Like
got sir thank you