mi problema es este, mylines1 es mi lista como ven la recorro con ciclos for y borro el espacio en blanco del final,bueno me genera la lista de esta forma
Código:
sb=myline.rsplit(" ",1)
mylines1.append(sb)
for a in mylines1:
    for b in a:
          mylines11.append(b)
for index, i in enumerate(mylines11):
    for x in range(1,200):
        if "Transacciones" in i:
            try:
                t1=re.search("(Ingresos.*)",mylines11[index+x])
            except:pass
            if not (t1) :
               
                reporte2=mylines11[index+x]
                reporte1.append(reporte2)
                print reporte2
            else:
                break
Código:
Gastos
06/05/20
20
01:37:30
p.m.
[RAYA]
2050.00
06/05/20
20
01:37:42
p.m.
[RENTA]
100.00
06/05/20
20
01:37:53
p.m.
[REPARTIDOR]
220.00
06/05/20
20
01:38:12
p.m.
[TORTILLAS]
310.00
06/05/20
20
01:39:05
p.m.
[FRUTERIA
(ABONO
NOTA
MAY-3)]
200.00
06/05/20
20
01:39:58
p.m.
[QUESO
(ABONO
NOTA
MAY-1)]
200.00
06/05/20
20
01:41:32
p.m.
[GMC]
200.00
06/05/20
20
01:41:42
p.m.
[IMSS]
200.00
06/05/20
20
01:42:00
p.m.
[PEPSI]
382.00
06/05/20
20
01:42:12
p.m.
[MARLIN]
350.00
06/05/20
20
[OXXO]
31.00
01:42:28
p.m.
06/05/20
20
01:45:02
p.m.
[GAS
CILINDRO
(COMPLEMENTO)]
350.00
06/05/20
20
01:45:50
p.m.
[CHILE (ABONO)]
200.00
06/05/20
20
02:08:59
p.m.
[CARNE]
2000.00
Total
6,793.00
Tarjeta de Crédito
0.00
Total de Efectivo y Tarjetas
6,793.00
lo que quiero hacer es esto
Código:
[GAS
CILINDRO
(COMPLEMENTO)]


 
  




 Autor
 Autor
		



 En línea
									En línea
								

 
						 
						