Professional Documents
Culture Documents
Fall22 DS Quiz 2 Solution
Fall22 DS Quiz 2 Solution
Fall22 DS Quiz 2 Solution
Name: Date:
Section: Marks: 30
c. Is the set A={((x , y ) ,(3 y ,2 x , x + y)): x , y ∈ R a function? If so, what is its domain,
codomain and range?
d. Determine, whether the relation R on the set of all people is reflexive, symmetric, and
transitive where ( a , b ) ∈ R if and only if,
i. a is taller than b
Section: Marks: 30
e. Determine, whether the relation R on the set of all webpages is reflexive, symmetric, and
transitive where ( a , b ) ∈ R if and only if,
ii. There are no common links found on both webpage a and webpage b
iii. There is a webpage that includes links to both webpage a and webpage b
Relation R could be
R ( a , b ) =There∃ a link c such that a ∈ LinksOutof ( c ) , b ∈ LinksOutof ( c )
f. Calculate time complexity for following loops. Draw table and find value of k and range
of k respectively.
for ¿
for ¿
for (∫ j=n ; j∗j >0 ; j/¿ 2)
Section: Marks: 30