Quiz 4
.pdf
keyboard_arrow_up
School
University of Illinois, Urbana Champaign *
*We aren’t endorsed by this school
Course
543
Subject
Computer Science
Date
Jan 9, 2024
Type
Pages
9
Uploaded by cheng-han
Quiz 4
Due
No due date
Points
16
Questions
16
Available
Dec 7, 2023 at 12:01am - Dec 11, 2023 at 11:59pm
Time Limit
90 Minutes
Score for this quiz: 15
out of 16
1 / 1 pts
Question 1
Consider the problem of creating a 3D reconstruction of the interior of
the Memorial Stadium using many images taken on different game
days. Which of the following statements below is the LEAST
accurate?
True
Correct!
1 / 1 pts
Question 5
In the given figure, who is taller?
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
Related Questions
Correct answer will be upvoted else Multiple Downvoted. Don't submit random answer. Computer science.
You are given a parallel table of size n×m. This table comprises of images 0 and 1.
You can make such activity: select 3 distinct cells that have a place with one 2×2 square and change the images in these cells (change 0 to 1 and 1 to 0).
Your assignment is to make all images in the table equivalent to 0. You are permitted to make all things considered 3nm activities. You don't have to limit the number of activities.
It tends to be demonstrated that it is consistently conceivable.
Input
The principal line contains a solitary integer t (1≤t≤5000) — the number of experiments. The following lines contain portrayals of experiments.
The principal line of the depiction of each experiment contains two integers n, m (2≤n,m≤100).
Every one of the following n lines contains a parallel line of length m, depicting the images of the following column of the table.
It is…
arrow_forward
Not sure how to do this. Need help
arrow_forward
55
arrow_forward
Problem
You are given a table with n rows and m columns. Each cell
is colored with white or black. Considering the shapes
created by black cells, what is the maximum border of
these shapes?
A shape is a set of connected cells. Two cells are connected
if they share an edge. Note that no shape has a hole in it.
Input format
• The first line contains t denoting the number of test
cases.
• The first line of each test case contains integers n, m
denoting the number of rows and columns of the
matrix. Here, # represents a black cell and '.'
represents a white cell.
• Each of the next n lines contains m integers.
arrow_forward
So, one of these statements is correct? It is impossible to display on a single map several layers (data) using different coordinate systems. For GIS purposes, it is allowed for data to include several coordinate systems. A map may display several different layers of data, each with its own set of coordinates. A map's layers may not align correctly if you use several coordinate systems to display them. Those things are not included
arrow_forward
In a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game.
CLEAR SOLUTION
arrow_forward
In a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game.
A. The game is fair.
B. The game is unfair to Lisa.
C. The game is unfair to Teddy.
D. More information is needed.
complete solution
arrow_forward
In a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game.
COMPLETE SOLUTION
arrow_forward
Description: There are 5 philosophers sitting around a table and try to eat from the center of the table. 5 chopsticks also lay on the table. Let us call the 5 philosophers in clockwise P1, P2, ...P5. There also 5 chopsticks clockwise S1, S2, ..., S5 on the table. There are only one chopstick between every two philosophers. Every right hand chopstick will have the same index as the philosopher. For example, on the right hand side of P1, the chopstick is called S1. And every left hand side chopstick number is 1+number of the philosopher.
A philosopher spend random time to think, then he feel hungry and try to eat.
The middle dish can provide enough food for everyone at the same time.
But a philosopher only can start to eat when he picked up two chopsticks from left hand side and right hand side to form a pair of chopsticks.
If a philosopher take one chopsticks, he will try to fight with neighbours to get another one, and never back off to put down the one in his hand.
Once the…
arrow_forward
last attempt. will give like if correct. please help
arrow_forward
1-Using Sage, create an elliptic curve with parameters a = 21 and b =10 and modulo 337
2- What is the order of the curve?
3- print the first 10 points in the curve
4- Plot all the point on the elliptic curve please provide screen shots too
Also be new not copying from previous answers
arrow_forward
You have an infinite number of 4 types of lego blocks of sizes given as (depth x height x width):
dhw111112113114
Using these blocks, you want to make a wall of height and width . Features of the wall are:- The wall should not have any holes in it.- The wall you build should be one solid structure, so there should not be a straight vertical break across all rows of bricks.- The bricks must be laid horizontally.
How many ways can the wall be built?
Example
The height is and the width is . Here are some configurations:
These are not all of the valid permutations. There are valid permutations in all.
Function Description
Complete the legoBlocks function in the editor below.
legoBlocks has the following parameter(s):
int n: the height of the wall
int m: the width of the wall
Returns- int: the number of valid wall formations modulo
Input Format
The first line contains the number of test cases .
Each of the next lines contains two space-separated integers and .…
arrow_forward
Starting from 2021, the square roots of 100 integers are calculated.The 2 digits after the comma of the results found are kept and the remaining decimal part is discarded. ( For exampleThe number 3.316624 is taken as 3.31.) The obtained results are summed and the number A is found.Starting from 2021, the square roots of 100 integers are calculated.The 3 digits after the comma of the results found are kept and the remaining decimal part is discarded. ( For exampleThe number 3,316624 is taken as 3,316.) The obtained results are added and the number B is found.What is the difference in thousandths between B and A?
arrow_forward
Add the missing pieces from checkpoint B while using this code
arrow_forward
Please help solve this test. Ty
arrow_forward
The Ancient Mesopotamians associated each of their deities with a sacred number. An
artist has created figurines of the main deities with the weight corresponding to their
respective number. The artist wants to ship the figurines to an art gallery using boxes
each holding a maximum weight of 90 kilograms. The numbers in the table represent
the weight in kilograms of the figurines:
figurine
Adad
Anum
Ea
Enlil
Girra
Ishtar
Marduk
Ninlil
Ninurta
Nuska
number / weight [kg]
6
60
40
50
10
15
10
45
50
10
Shamash
20
14
Shakan
Sin
30
(a) Find the lower bound & for the number of boxes required to fit all figurines.
(b) Use the first fit decreasing algorithm to estimate the minimum number of boxes
required to ship all figurines. Does the first fit decreasing algorithm give an optimal
solution?
(c) Find by trial and error a solution needing only l boxes.
arrow_forward
Question 18
The following question uses a robot in a grid of squares. The robot is represented as a triangle, which is initially facing toward the top of the grid.
The following code segment moves the robot around the grid. Assume that n is a positive integer.
arrow_forward
Practice Test Question #1:
You want to solve a simplified 4x4 version of the Sudoku game with the following grid configuration (image attached):
(a) Show the first ten steps of backtracking search on the sample provided, where you order the variables in increasing order first by row, then by column (in English reading-order), and the values from lowest to highest (1 to 4). Recall that backtracking search uses a depth-first strategy to expand the search tree.
(b) Show the first ten steps of backtracking search on this problem with one-step forward checking, with the same variable ordering.
arrow_forward
Assignment
As an initiation into the study of ethics, carefully read each of the following scenarios. After
reflection, come up with your own answer to each of the questions.
Scenario 1
Alexis, a gifted high school student, wants to become a doctor. Because she comes from a poor
family, she will need a scholarship in order to attend college. Some of her classes require
students to do extra research projects in order to get an A. Her high school has a few older PCs,
but there are always long lines of students waiting to use them during the school day. After
school, she usually works at a part-time job to help support her family.
One evening Alexis visits the library of a private college a few miles from her family's
apartment, and she finds plenty of unused PCs connected to the Internet. She surreptitiously
looks over the shoulder of another student to learn a valid login/password combination. Alexis
returns to the library several times a week, and by using its PCs and printers she…
arrow_forward
Obtain information about what the colors on an electrical resistor mean. Create a table showing the electrical resistor codes. Your table should have a column with the colors Black, Brown, Red, Orange, Yellow, Green, Blue, Violet, Gray, White, Gold, and Silver, and a column showing their digit values. Imagine that you are making this table for others to use; therefore, include at least one example of how to read the codes on electrical resistors for each of 3-band, 4-band, 5-band, and 6-band codes at the bottom of your table.
arrow_forward
Can you help me with this code I only need help with two of the parts. I have attached my code in the photo.
question that i need help with:
the Eight Puzzle consists of a 3 x 3 board of sliding tiles with a single empty space. For each configuration, the only possible moves are to swap the empty tile with one of its neighboring tiles. The goal state for the puzzle consists of tiles 1-3 in the top row, tiles 4-6 in the middle row, and tiles 7 and 8 in the bottom row, with the empty space in the lower-right corner.you will develop two solvers for a generalized version of the Eight Puzzle, in which the board can have any number of rows and columns.
A natural representation for this puzzle is a two-dimensional list of integer values between 0 and r · c -1 (inclusive), where r and c are the number of rows and columns in the board, respectively. In this problem, we will adhere to the convention that the 0-tile represents the empty space.tasks:
In the TilePuzzle class, write a method…
arrow_forward
Lighting Calculations
Let p be a point in the OCS, n be the point's surface normal in the OCS, lwcs be the light direction in the WCS, and ewes be the eye position in the WCS. All four vectors are 4D
homogeneous vectors with 0 or 1 in the last position, as appropriate. Let M be the object-to-world transform, V be the world-to-view transform, and P be the view-to-CCS transform.
Which sets of transformed point, normal, light direction, and eye position below can be used together to compute the Phong illumination at the point? Select all that apply.
• M
Pocs,
• M Pocs
VM Pocs
●
●
M nocs,
M nocs,
VM nocs,
PVM Pocs
lwcs, ewcs
Mlwes, Mewcs
Vlwes (ewes is not available)
PVlwes, PVewes (all followed by division by the fourth coordinate)
PVM nocs
arrow_forward
An image has four possible gray levels, named r1, r2, r3, and ra. The probabilities of each gray level are: p(r1) = 0.066666666666667, p(r2) = 0.34666666666667, p(r3)
= 0.42666666666667, and p(ra) = 0.16. If variable length coding is used to compress the image, the shortest code will be associated with which probability?
Select one:
O a. 0.8533
Ob. 0.0667
O. 0.4267
Od. 0.2133
Oe. 0.0333
arrow_forward
"""You are given an n x n 2D mat representing an image.
Rotate the image by 90 degrees (clockwise).
Follow up:Could you do this in-place?"""
# clockwise rotate# first reverse up to down, then swap the symmetry# 1 2 3 7 8 9 7 4 1# 4 5 6 => 4 5 6 => 8 5 2# 7 8 9 1 2 3 9 6 3
def rotate(mat): if not mat: return mat mat.reverse() for i in range(len(mat)): for j in range(i): mat[i][j], mat[j][i] = mat[j][i], mat[i][j] return mat
if __name__ == "__main__": mat = [[1, 2, 3], [4, 5, 6], [7, 8, 9]] print(mat) rotate(mat) print(mat).
arrow_forward
Can you help me with this code becuase I only need help with one of the parts. I have attached my code below and task the needs to answered but you have to use my code and the variables which I have provided in the photo.
question that i need help with:
the Eight Puzzle consists of a 3 x 3 board of sliding tiles with a single empty space. For each configuration, the only possible moves are to swap the empty tile with one of its neighboring tiles. The goal state for the puzzle consists of tiles 1-3 in the top row, tiles 4-6 in the middle row, and tiles 7 and 8 in the bottom row, with the empty space in the lower-right corner.you will develop two solvers for a generalized version of the Eight Puzzle, in which the board can have any number of rows and columns.
A natural representation for this puzzle is a two-dimensional list of integer values between 0 and r · c -1 (inclusive), where r and c are the number of rows and columns in the board, respectively. In this problem, we will adhere…
arrow_forward
This is not an graded assignment please do this three questions show the work and explain how you got the answer !
arrow_forward
Upsampling an Image using Interpolation TechniquesThere are a number of techniques that can be used to upsample an image.In this assignment, you are expected to implement Interpolation methods (such as Lagrangian Interpolation, Divided Difference, etc.) for three different images and compare the results.
Example Code Python:
orgImage = cv2.imread("dene.png")w, h, d = orgImage.shapexResized = int(w * scale);yResized = int(h * scale);....cv2.imwrite("resizedImage.png", resizedImage)
Example Code Matlab:I = imread('pen.png');figure;imshow(I);
[w, h, d ]= size(I)R = I(:,:,1);G = I(:,:,2);B = I(:,:,3);
%for cubic spline write findcoefficients method[ax,bx,cx,dx ] = findCoefficients(R);[ay,by,cy,dy ] = findCoefficients(G);[az,bz,cz,dz ] = findCoefficients(B);
....R_new = ax(i)*i_d.^3 + bx(i)*i_d.^2 + cx(i)*i_d + dx(i);G_new = ay(i)*i_d.^3 + by(i)*i_d.^2 + cy(i)*i_d + dy(i);B_new = az(i)*i_d.^3 + bz(i)*i_d.^2 + cz(i)*i_d + dz(i);
arrow_forward
Paola downloads the latest first-person shooter (FPS) game all her friends are talking about. She starts to create her avatar and discovers that all the characters are male. There are not even alien or silly characters, only male. What type of bias occurred during the product design?
A)attractiveness bias
B)affinity bias
C)age bias
D)gender bias
arrow_forward
Map coloring problem with {Red, Green, Blue).
Assume that Arizona and Colorado do not share any border, and Utah and New Mexico do not share any border.
Southwestern States
Pacific
Ocean
ܞ
W
Key
Oregon
Sacramento
★
State
Capital
Carson
State
Boundary
Water
CEnchantedLearning.com
City
Névada
California
Idaho
Salt Lake
City
Utah
Arizona
Phoenix
MEXICO
Wyoming
Denver
Colorado
Santa
Fe
New
Mexico
Texas
Kansas Nebraska
Oklahoma
Texas
Please answer the following questions.
1. Which state should be selected to color first based on the heuristic of most constraining variable (degree heuristic)?
2. Assume our current assignment is {Nevada= Red, Arizona = Green}, which state(s) should be selected to color next based on the heuristic of minimum remaining
value?
3. Assume our current assignment is {Arizona = Blue, Utah = Red} and we select California to color next, which color should we select based on the heuristic of least
constraining value?
4. Assume our current assignment is {California =…
arrow_forward
Please answer this
arrow_forward
SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Related Questions
- Correct answer will be upvoted else Multiple Downvoted. Don't submit random answer. Computer science. You are given a parallel table of size n×m. This table comprises of images 0 and 1. You can make such activity: select 3 distinct cells that have a place with one 2×2 square and change the images in these cells (change 0 to 1 and 1 to 0). Your assignment is to make all images in the table equivalent to 0. You are permitted to make all things considered 3nm activities. You don't have to limit the number of activities. It tends to be demonstrated that it is consistently conceivable. Input The principal line contains a solitary integer t (1≤t≤5000) — the number of experiments. The following lines contain portrayals of experiments. The principal line of the depiction of each experiment contains two integers n, m (2≤n,m≤100). Every one of the following n lines contains a parallel line of length m, depicting the images of the following column of the table. It is…arrow_forwardNot sure how to do this. Need helparrow_forward55arrow_forward
- Problem You are given a table with n rows and m columns. Each cell is colored with white or black. Considering the shapes created by black cells, what is the maximum border of these shapes? A shape is a set of connected cells. Two cells are connected if they share an edge. Note that no shape has a hole in it. Input format • The first line contains t denoting the number of test cases. • The first line of each test case contains integers n, m denoting the number of rows and columns of the matrix. Here, # represents a black cell and '.' represents a white cell. • Each of the next n lines contains m integers.arrow_forwardSo, one of these statements is correct? It is impossible to display on a single map several layers (data) using different coordinate systems. For GIS purposes, it is allowed for data to include several coordinate systems. A map may display several different layers of data, each with its own set of coordinates. A map's layers may not align correctly if you use several coordinate systems to display them. Those things are not includedarrow_forwardIn a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game. CLEAR SOLUTIONarrow_forward
- In a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game. A. The game is fair. B. The game is unfair to Lisa. C. The game is unfair to Teddy. D. More information is needed. complete solutionarrow_forwardIn a classroom election, two presidential candidates, namely, Lisa and Teddy, both garnered the same number of total votes. As such, they decided to play a custom dice game to determine the winner of the election. In this game, a player needs to roll a pair of dice. Teddy will win the game if the sum is odd whereas Lisa will be declared winner if the sum results to even. However, prior to the start of the game, Teddy complained that the custom dice game is biased because according to him, the probability of an even result is 6/11, and for odd - only 5/11. Verify Teddy's claim and evaluate the fairness of the game. COMPLETE SOLUTIONarrow_forwardDescription: There are 5 philosophers sitting around a table and try to eat from the center of the table. 5 chopsticks also lay on the table. Let us call the 5 philosophers in clockwise P1, P2, ...P5. There also 5 chopsticks clockwise S1, S2, ..., S5 on the table. There are only one chopstick between every two philosophers. Every right hand chopstick will have the same index as the philosopher. For example, on the right hand side of P1, the chopstick is called S1. And every left hand side chopstick number is 1+number of the philosopher. A philosopher spend random time to think, then he feel hungry and try to eat. The middle dish can provide enough food for everyone at the same time. But a philosopher only can start to eat when he picked up two chopsticks from left hand side and right hand side to form a pair of chopsticks. If a philosopher take one chopsticks, he will try to fight with neighbours to get another one, and never back off to put down the one in his hand. Once the…arrow_forward
- last attempt. will give like if correct. please helparrow_forward1-Using Sage, create an elliptic curve with parameters a = 21 and b =10 and modulo 337 2- What is the order of the curve? 3- print the first 10 points in the curve 4- Plot all the point on the elliptic curve please provide screen shots too Also be new not copying from previous answersarrow_forwardYou have an infinite number of 4 types of lego blocks of sizes given as (depth x height x width): dhw111112113114 Using these blocks, you want to make a wall of height and width . Features of the wall are:- The wall should not have any holes in it.- The wall you build should be one solid structure, so there should not be a straight vertical break across all rows of bricks.- The bricks must be laid horizontally. How many ways can the wall be built? Example The height is and the width is . Here are some configurations: These are not all of the valid permutations. There are valid permutations in all. Function Description Complete the legoBlocks function in the editor below. legoBlocks has the following parameter(s): int n: the height of the wall int m: the width of the wall Returns- int: the number of valid wall formations modulo Input Format The first line contains the number of test cases . Each of the next lines contains two space-separated integers and .…arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education