import pandas as pd import numpy as np a = [ 92812191 , 189291281 , 9218291 , 1298182 ] b = [ ' a ' , ' ab ' , ' abc ' , ' abcd ' ] c = [ 1 , 12 , 123 , 1234 ] d = [ 9 , 98 , 987 , 9876 ] e = [ 9 ,np.NaN, 98 , 987 , 9876 ] print ( pd. Series ( a ,[ 1 , 2 , 3 , 5 ] )) smarks = { ' name ' : [ ' rain ' , ' drake ' , ' larry ' ] , ' grade ' : [ ' A1 ' , ' A2 ' , ' B1 ' ] } df1 = pd. DataFrame ( smarks ) print ( df1 ) import pandas as pd df1 = pd. DataFrame ( { ' first ' : [ 10 , 20 , 30 , 40 ] , ' second ' : [ 4 , 24 , 7 , 9 ] , ' third ' : [ 30 , 40 , 50 , 70 ] } ) df2 = pd. DataFrame ( { ' first ' : [ 17 , 18 , 19 , 20 ] , ' second ' : [ 14 , 15 , 17 , 19 ] , ' third ' : [ 13 , 14 , 15 , 17 ] } ) print ( df1 ) print ( df2 ) df3 = df1. rsub ( df2 ) print ( df3 ) df1 = df1. reindex ( [ 1 , 2 , 3 , 4 ], copy = False ) print ( df1 ) import p