stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
ICEM-BE- Day 2 -Obj 4-Functional Programming Concepts Flashcards | StudBud
Explore
/
ICEM-BE- Day 2 -Obj 4-Functional Programming Concepts
What does reduce() require?
Which module formats the time string?
ICEM-BE- Day 2 -Obj 4-Functional Programming Concepts
10 terms
·
StudBud Administration
Imported from external platform
Flashcards
10 cards
F
Practice quiz
P
Host live
L
Questions
10
Answers
1
Which module formats the time string?
datetime
os
timeit
json
2
What does reduce() require?
Only function
Function and list
Only list
No arguments
3
Which decorator creates a POST endpoint?
@post.route
@app.get
@app.post
@endpoint.post
4
What is the default response format?
XML
JSON
CSV
HTML
5
What does curl do?
Formats JSON
Creates models
Runs server
Sends HTTP requests
6
What does @app.get("/time") return?
Server name
Error message
Current time
List of numbers
7
True or false: set() removes duplicates
False
True
8
Which import is needed for BaseModel?
from pydantic
from fastapi
from typing
from functools
9
What does Query(...) do?
Ignores input
Returns error
Requires parameter
Sorts data
10
Which function calculates the product?
sum()
map()
filter()
reduce()