Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

find no of iterations in python

ps = 1000
print("%12s%18s" % ("Problen Size", "iterations"))
for count in range(5):
  number = 0
  work = 1
  for j in range(ps):
    for k in range(ps):
      number += 1
      work += 1
      work -= 1

  print("%12d%18d" % (ps, number))
  ps *= 2
Comment

PREVIOUS NEXT
Code Example
Python :: numpy np sign change in df pandas zero crossing 
Python :: how to put 2 code n 1 line in python 
Python :: nibabel expand dimension 
Python :: plot row vs column in dataframe python 
Python :: unction which takes in a list of integers and returns a dictionary of the five number summary.. 
Python :: how to restore windows security 
Python :: python pipe select where 
Python :: blockchain.py 
Python :: QuizListView login required django 
Python :: python numpy bbox 
Python :: Define a python function day_of_week, which displays the day name for a given date supplied in the form (day,month,year). 
Python :: cosine similiarity OF A VECTOR WITH OTHER VECTORS IN A MATRIX 
Python :: aes in django 
Python :: terneray operator in python 
Python :: pandas read csv read all columns except few columns 
Python :: matplotlib annotate align center 
Python :: fetch api python 
Python :: python wikipedia 
Python :: python shift array 
Python :: select specific columns in sqlalchemy 
Python :: inline keyboard telegram bot python 
Python :: python order list of dictionaries by value 
Python :: list arguments of function python 
Python :: python bool() 
Python :: str in python 
Python :: python find if part of list is in list 
Python :: formatting strings in python 
Python :: pandas read_csv drop column 
Python :: numpy indexing 
Python :: self python 
ADD CONTENT
Topic
Content
Source link
Name
2+7 =