Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

create a sequence of numbers in python

list(range(11, 17))
#Creates the following list
[11, 12, 13, 14, 15, 16]
Comment

sequence with numbers in python

step = 2
vec = [1,2,3,4,5]
vec2 = [i/step for i in range(len(vec))]

# vec2 = [0.5, 1, 1.5, 2, 2.5]
Comment

PREVIOUS NEXT
Code Example
Python :: python catch any exception 
Python :: create 2d array with rows and columns 
Python :: how to end a while loop python 
Python :: deleting an object in python 
Python :: python svg viewing 
Python :: Python recursively find files with specific ext 
Python :: df set index 
Python :: get length of string python 
Python :: how many numbers greater than 100 using pytho 
Python :: pandas in python 
Python :: how to append substring to string in specific position in python 
Python :: Requested runtime (python-3.7.5) is not available for this stack (heroku-20). 
Python :: guardar plot python 
Python :: python subprocess 
Python :: demonstrating polymorphism in python class 
Python :: how to convert categorical data to numerical data in python 
Python :: python dataframe contains value 
Python :: python *args and **kwargs 
Python :: pytorch get non diag element 
Python :: python replace string with int in list 
Python :: inherit functions from other classes 
Python :: opkg install python-lxml_2.2.8-r1_mips32el.ipk 
Python :: python set current working directory debugging 
Python :: pd dataframe 
Python :: find median pandas 
Python :: os.listdir specific extension 
Python :: email confirmation django 
Python :: find rules of decision tree python 
Python :: python get timestamp 2020-04-23T12:00:00Z 
Python :: python find index 
ADD CONTENT
Topic
Content
Source link
Name
8+5 =