List Assignment, Python Programming

Assignment Help:
Task
This problem creates a list containing names. The list of names will be printed, sorted, printed again in the new sorted order, written to a new output file, and searched. Carefully read chapter 8 to find examples of the techniques and functions you need to solve this problem. You must design your solution using these 4 sub-functions:

1) Input the names from the data file names.txt (which is located in the Homework 8 folder in D2L) into a list and return the list to main.
2) Print the names one per line and single-spaced. Call this function (twice) passing the list of names to it for printing before and after they are sorted (do the sorting in main).
3) Pass the sorted list of names to a function which writes the list to a new output file (use a name different than the input file’s name) with one name per line.
4) Pass the sorted list of names to a function which asks the user to enter a name and then indicate whether the name entered is found in the list or not. If the name is found in the list, its position (i.e. index) is also printed.

The data file for this program contains 30 names each with the format Last, First. This value is to be processed as one, not separately. The user enters the search name in this same format as one string (i.e. not separately as Last and First names) unless your program is coded to concatenate them appropriately. Use Notepad to look at (and print) the test data file names.txt.

When testing your program, use the last and first names in the list along with one in the middle. Also test for one not in the list. Open the new output file with Notepad to verify that it contains the sorted list of names, one per line.

For 5 extra credit points, create a loop so the user can enter additional names to be searched for without having to rerun the entire program (show this loop in the logic diagram and include it in your program).

Submit each of the following in electronic format following class standards inside a compressed folder using the D2L drop boxes for Homework 8.

Use the logic diagrams drop box to submit:
1. A hierarchy chart drawn with MS-Visio. (2 points)
2. Program flowcharts drawn with MS-Visio showing your logical solution. (9 points)

Use the program drop box to submit:
3. A Python program implementing the solution shown in your logic diagrams. (14 points)

Related Discussions:- List Assignment

A method defination , De?nition   A method de?nition has the abstrac...

De?nition   A method de?nition has the abstract form: def ( , ..., ): ...   There are essentially three parts: is a name for

Basics of python-introduction, Basics of python-introduction Python is...

Basics of python-introduction Python is designed for easy interaction between a user and the system. It goes with  an inter­ active function  known as  a shell or listener.  T

Robotics, how to started robotics proggraming in begning

how to started robotics proggraming in begning

Python game assignment, I have python game project which is due by next Tue...

I have python game project which is due by next Tuesday. Do you think that I can get it on time if I order today?

Turtle graphics module in python programming language, Your assignment for ...

Your assignment for the semester will involve the development of a system for drawing trees using the Python programming language and the turtle graphics module (turtle.py). Comple

Python programme comparing for and while loops, 1)    Write a python progra...

1)    Write a python programmecomparing for and while loops like the following. Math Times table For Loop: 2x1=2 2x2=4 ..... 2x12=24 While Loop: 3x1=3 3x

Programming embedded systems-programming models, Programming models Ju...

Programming models Just  as there  are several methods for organizing entire  software systems, there  are  different strategies for formally expressing computational processe

While loop, You should use for whenever you can, because  it creates  the s...

You should use for whenever you can, because  it creates  the structure of your  loops clear. Sometimes, however, you require to do an operation various times, but you don't want t

Data wrangling, Ask quesICT702 TASK 2 1 2018 Semester 2 Data Wrangling Due ...

Ask quesICT702 TASK 2 1 2018 Semester 2 Data Wrangling Due in two parts - Friday of Week 9 and Week 12 Below Zero - ice cream store The local ice-cream store needs a new ordering s

Algorithms, how to calculate area of a square in square metres

how to calculate area of a square in square metres

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd