Suppose I have these 2 for loops:
Loop a:
for (int i = 0; i < 10; i++)
{
Task.Delay(1000)
}
Loop B:
for (int i = 0; i < 10; i++)
{
Task.Delay(200)
}
I want to run the loops and loop B should only run after each index of A is complete (The index of B should always be lower than A). When loop B runs, I don't want loop A to pause until loop B is complete. Is there a way to do this?
Note: The Task.Delay is just a placeholder