+ 3

My first Python code

My first python program: an approximation of pi with Monte Carlo method. Is it possible to make the code shorter? https://code.sololearn.com/cTO6UKXuhOI0/?ref=app

3rd Dec 2017, 1:51 PM
S K Lurk //\●●/\\
S K Lurk //\●●/\\ - avatar
1 Odpowiedź
0
you can use a for loop to shorten it. you won't need to initialize a counter and update it.
3rd Dec 2017, 10:46 PM
Kevin Oudai
Kevin Oudai - avatar