Python Forum
Need some help with list and dictionary .txt
Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need some help with list and dictionary .txt
#1
Hello buddies, I need some help with 4 questions , thanks for your time
 
Implement a program for:
• Read data in files of format similar to the examples provided
• Represent those data in appropriate structures (lists and dictionaries)
• Which company had most billing in month X?
• Which company had the most expenses in month X?

I really try to solve it but dont have ideia how to do .txt files and inplanted in the 2 last questions , can you help my guys ?





And the examples are :

""""
Company.txt

Company number                Company name

 12345678         --->       Stones Industry
 50609693         --->       Cakes and soda
 53453453         --->        Motos and cars

 """""
Movements.txt



FiscalNumber  Month      Billing     Expenses
12345678       1         3780,24       1839,75
50609693       1         7006,54       6500,34
12345678       2         4560,00       5640,54
53453453       1         13760,00      12049,62
12345678       3         7654,83       8732,99
53453453       2         15708,93      10495,00


""""
Reply


Messages In This Thread
Need some help with list and dictionary .txt - by GeekLife97 - Jan-20-2017, 12:06 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Loop through elements of list and include as value in the dictionary Rupini 3 2,657 Jun-13-2020, 05:43 AM
Last Post: buran
  How can details be dynamically entered into a list and displayed using a dictionary? Pranav 5 2,931 Mar-02-2020, 10:17 AM
Last Post: buran
  Functions returns content of dictionary as sorted list kyletremblay15 1 2,052 Nov-21-2019, 10:06 PM
Last Post: ichabod801
  Dictionary/List Homework ImLearningPython 22 10,577 Dec-17-2018, 12:12 AM
Last Post: ImLearningPython
  making a dictionary from a list, one key with multiple values in a list within a list rhai 4 3,611 Oct-24-2018, 06:40 PM
Last Post: LeSchakal

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020