Post

@PythonPr Answer: (C) 0 0
The range(1) function generates a sequence of numbers starting from 0 up to (but not including) 1, which means it only contains the number 0.
The outer loop for i in range(1) runs once, with i assigned the value 0.
Inside the outer loop, the inner
English

@PythonPr Answer: C) 0 0
range(1) starts at 0 and stops before 1, so the only value is 0. That means the loops run once with i = 0 and j = 0.
English

@PythonPr Answer: C) 0 0 ✅
Why:
range(1) runs only once with value 0.
Outer loop: i = 0
Inner loop: j = 0
print(i, j) prints 0 0 once.
English

@PythonPr Answer: C. 0 0
Solution: Just need to be clear on `range` usage with a single argument.
range(a) is equivalent to range(0, a)
ie, starting from 0, stopping at a (a won't be in the range).
So, range(1) is range(0, 1)
starting from 0, stopping before 1.
So just 0
+
English

@PythonPr Option C. 0 0
Fundamental syntax.
But in our HFT architecture, we avoid nested loops for execution. Vectorized calculations with NumPy are the only way to beat the latency. ⚡️
English

@PythonPr Answer 0, 0
Because the range of iteration starts from 0 till less than 1 for both nested loops so it will print 0, 0.
English

@PythonPr The output is 0,0: in inner and outer range(1), starts at zero and stops before 1.
English

@PythonPr C . 0 0
Range passed is 1 which means it will print number from 0 to 1 but excluding 1 .
English


























