0
What underscore is doing in python
for _ in range():
4 Réponses
+ 6
it is quite common to use this as "disposable loop variable" when you do not need the loop-variable inside the loop:
for _ in range(10):
print("Hello world")
other than a code like this where you use the loop-variable inside the loop:
for i in range(10):
do_something(i)
+ 2
_ is just a local variable name for the loop.
Instead of _ it could be i, j, k or any other name
0
Thanks a lot
0
def fit(self, xTest, yTest)
for _ in ():
self.update_weights()