Description
Problem Definition:
Given a list of numbers and words, find the count of each element type in the list.
Example:
Example: L = [2, 3, ’word’, -1, ’python programming language’, 9, 321]
Count of Numbers: 5
Count of words: 4
Write a pure python code (No external libraries) to achieve the following:
-
Create a function the will randomly generate a list of N numbers and words. Numbers and words count are random and the order is random too.
-
Create two functions to calculate the desired output as follows:
-
-
Procedural code by using loops
-
-
-
Functional code by using list comprehension.
-
-
Use TimeIt standard library and matplotlib to present the performance difference among the 2 solutions for different list sizes (N=100, 1000, 10000, 100000).
Exercise 2 – Simple Student Grading System – memory based
In a given course the following applies (a CSV data set exams.csv file is attached):
-
The system track students by student name and unique ID.
-
Grades are based on:
-
Exams Score (40% of the final grade) o Projects Score (30% of the final grade) o Quizzes Score (30% of the final grade)
o [90-100]:A ; [80-90): B ; [20-80): C ; [10-20): D ; [0-10): F
Create a data structure (dict!) to store the class related information.
Provide the system user with a console based menu as follows:
-
Load the data set from exams.csv file (file is comma delimited).
-
Print a list of student names, final scores, and letter grades sorted by names.
-
Print score summary (Student Count, Min, Max, mean, mode, and standard deviation)
-
Identify values that are larger than the mean and two times standard deviation
-
Plot a pie chart showing the final letter grades distribution.
-
Create box plots parameters (not drawing them but just computing the numbers [min, max,
medial, Q1, Q3] for a box plot).
-
-
Exit the system.
-
-
Make your own assumptions but usability counts
-
Functions and readability counts.
-
Only core python built-in data types.
Exercise 3 –
Pick an extension library from PyPI or other sources (something of interest to you). Summarize the functionality provided by the library (one paragraph) and show a usage example.
Document step-by-step how to run the example provided.