The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | Jul 2017 |
| Last Sign in: | 304 Weeks Ago, 5 Days Ago |
| Questions Answered: | 15833 |
| Tutorials Posted: | 15827 |
MBA,PHD, Juris Doctor
Strayer,Devery,Harvard University
Mar-1995 - Mar-2002
Manager Planning
WalMart
Mar-2001 - Feb-2009
Could someone please help me edit this Python code so that it'll work? I can't seem to get it fixed. I attached the python program along with a Microsoft Word document of the Flowchart and Pseudo Code for the program. I'm not sure if this is correct but someone said to make this revision,
Â
global dep global counts global QUIT dep = 0 counts[:6] = [0]*6 QUIT = 999 def getReady(): dep = (int(input("Enter dependents or QUIT to quit"))) def countDependents(): counts[dep] = counts[dep]+1 dep = input("Enter dependents or QUIT to quit") def finishUp(): print "Output Dependent counts " dep =0 while dep < 6: print dep ,",", counts[dep] dep=dep+1 def main(): getReady() while (dep != QUIT) : countDependents() finishUp() main()
Â
However, I'm extremely new to programming so I couldn't figure out how to properly place everything. Any help is appreciated!
----------- Â ----------- H-----------ell-----------o S-----------ir/-----------Mad-----------am ----------- Th-----------ank----------- yo-----------u f-----------or -----------you-----------r i-----------nte-----------res-----------t a-----------nd -----------buy-----------ing----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill----------- be----------- qu-----------ick-----------ly