Home > other >  Strives for the Python implementation cycle period
Strives for the Python implementation cycle period

Time:10-29

Everyone a great god help, want to realize the circulation in the excel transposed

For each device under the corresponding equipment types according to the operation of time sorting cost, because the time is not the same as the initial was put into operation, so want to put the first X years to class in the operation of the corresponding cost, the ideal situation is like this:

Beg you teach a great god!!!!!

CodePudding user response:

If do not clear in the EXCEL, if it is a python
The general idea is like this:
1, open the original data file
2. Dictionary list traversal,
Dictionary list about this
/
{' devcode ':' 04 m0009241611 ',
'list' : {' 7 ': {' routine maintenance: 0,' overhaul: 0, 'patrol' : 20551.06},
'8' : {' routine maintenance: 13777.62, 'overhaul: 0,' patrol ': 20551.06},
# the remaining life of data
}
},
{' devcode ':' 04 m0009241658 ',
'list' : {' 19: {' routine maintenance: 0, 'overhaul: 0,' patrol ': 20551.06},
"21" : {' routine maintenance: 13777.62, 'overhaul: 0,' patrol ': 20551.06},
# the remaining life of data
}
},


]

3, generated through 2 dictionary list, to write reports (mainly for operating equipment coding, fixed number of year)

4, to EXCEL
  • Related