I am writing a program in python where I give the user a list of things to do to some text data. We were given the example text data that we have to use in the program and it looks like this in the text file:

January 10 2018 236.9

January 11 2018 267.6

January 12 2018 278.1

January 13 2018 246.9

January 14 2018 262.3

The options that we are supposed to give the user are to read the file into a structure/class, to print the information back out to the user, to get the average output (the number value) and write it to a another file, and to pickle and unpickle the data. My question is would it be best to initially write the data to a class or a list to do all of these things?

New contributor
mgale is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

put on hold as off-topic by πάντα ῥεῖ, 200_success, Sᴀᴍ Onᴇᴌᴀ, IEatBagels, l0b0 Dec 7 at 1:04

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Code not implemented or not working as intended: Code Review is a community where programmers peer-review your working code to address issues such as security, maintainability, performance, and scalability. We require that the code be working correctly, to the best of the author's knowledge, before proceeding with a review." – πάντα ῥεῖ, 200_success, Sᴀᴍ Onᴇᴌᴀ, IEatBagels, l0b0
If this question can be reworded to fit the rules in the help center, please edit the question.

Browse other questions tagged or ask your own question.