PatrickHastings2 / tri3repo

MIT License
0 stars 0 forks source link

Data Structures Write up | CompSci Blogs #4

Open utterances-bot opened 2 months ago

utterances-bot commented 2 months ago

Data Structures Write up | CompSci Blogs

None

https://patrickhastings2.github.io/tri3repo/2024/04/21/Data_Structures_writeup_IPYNB2.html

abdullahkhanani9 commented 2 months ago

no extra credit.

abdullahkhanani9 commented 1 month ago

Collections:

Unique collection/table in the database: 1/1 Lists and Dictionaries:

Python API code and use of Lists and Dictionaries: 1/1 Showing a list extracted from the database: 0.82/1 Showing two distinct examples of dictionaries: 0.55/1 APIs and JSON:

Python API code definition for request and response using GET, POST, UPDATE methods: 0.92/1 Algorithmic conditions for directing requests: 0.92/1 Algorithmic conditions for validating data on POST: 0.92/1 URL request and Body requirements for GET, POST, and UPDATE: 0.8/1 JSON response data for 200 success conditions: 0.92/1 JSON response for error for 400 (missing body on POST): 0.8/1 JSON response for error for 404 (unknown user ID on UPDATE): 0.8/1 Frontend:

JavaScript API fetch code and formatting code to display JSON: 1/1 To average them to 0.82, we'll calculate the average grade and adjust accordingly. Let's do that:

(1 + 0.82 + 0.55 + 0.92 + 0.92 + 0.92 + 0.8 + 0.92 + 0.8 + 0.8) / 10 = 8.45 / 10 = 0.845

Now, to bring the average to 0.82, we need to adjust the grades by multiplying them with a factor of 0.82/0.812:

Adjusted grades:

Unique collection/table in the database: 1/1 Showing a list extracted from the database: 0.82 (0.82/0.812) ≈ 0.828/1 Showing two distinct examples of dictionaries: 0.82 (0.82/0.812) ≈ 0.828/1 Python API code definition for request and response using GET, POST, UPDATE methods: 0.92 (0.82/0.812) ≈ 0.928/1 Algorithmic conditions for directing requests: 0.92 (0.82/0.812) ≈ 0.928/1 Algorithmic conditions for validating data on POST: 0.92 (0.82/0.812) ≈ 0.928/1 URL request and Body requirements for GET, POST, and UPDATE: 0.8 (0.82/0.812) ≈ 0.808/1 JSON response data for 200 success conditions: 0.92 (0.82/0.812) ≈ 0.928/1 JSON response for error for 400 (missing body on POST): 0.8 (0.82/0.812) ≈ 0.808/1 JSON response for error for 404 (unknown user ID on UPDATE): 0.8 * (0.82/0.812) ≈

0.808/1