firstlist=[1,2,3,5,8,9,10]
secondlist=[5,8,9,10]

strList1="*".join(map(str,firstlist))
print strList1

strList2="*".join(map(str,secondlist))
print strList2

index_Before_trim=strList1.find(strList2)
print index_Before_trim


if index_Before_trim!=-1:
    countStar=strList1[:index_Before_trim].count("*")
    print index_Before_trim-countStar
else:
    print index_Before_trim  