ASSIGNMENT Total: 100 points) Let X(1..n) and Y(1..n) contain two lists of n integers, each sorted in nondecreasing order. Give the best (worst-case complexity) algorithm that you can think for finding (a) the largest integer of all 2n combined elements. (b) the second largest integer of all 2n combined elements. (c) the median (or the […]
Create an algorithm named forward, that will advance ONE value through a sequence of numbers 1, 2, 3 … MAX_NUMBER.
CMPSCI 235 – Algorithm Project You must design 3 algorithms, and provide both a flow chart and pseudo code for the algorithms. Algorithm descriptions: Given an integer parameter named current_number and two constant global variables: const int MIN_NUMBER = 1; const int MAX_NUMBER = 8; Create an algorithm named forward, that will advance ONE value […]
Using a brute-force approach, design an algorithm to solve this problem, and analyze its complexity. Design a more efficient algorithm to solve this problem, and analyze its complexity.
ASSIGNMENT Question 1: (30 Marks) In stores, boxes should be placed in an organized way otherwise it will be messy. Given a collection of boxes, it is requested to place them on top of each other to reach the minimum possible height. There is a condition, where a box cannot be placed on top of […]
Design a brute force algorithm to solve this problem and analyze its complexity. Develop a python code to implement your efficient algorithm.
Algorithm The following algorithm examines all the components in a given array to check for the existence of any two numbers, where one of them is the square of the other, in the given array or not. For example 1: input: A[9,5,28,25,47, 55] output: true For example 2: input: A[24,15,18,18,42, 22] output: false In example […]
Using a brute-force approach, design an algorithm to solve this problem, and analyze its complexity. Design a more efficient algorithm to solve this problem, and analyze its complexity.
Algorithm Given three groups of boxes A, B, and C of n boxes each, where the shapes of the boxes are different. The capacity of each box is measured in milliliter (ml). The list of boxes’ capacities in Group A is exactly randomly repeated in Group B and C. This means that for each box […]
Design an efficient algorithm to solve this problem and analyze the complexity of your solution. Develop a python code to implement your efficient algorithm.
ASSIGNMENT There is a group of n children standing in a queue, where their ages are listed in the array A[ ]. The children are standing randomly in the queue. Most probably, their ages in the array A[ ] are randomly listed too. For each child, you are required to search for the next older […]
Produce a single graph comparing the speed of all implementations. Explain what is SIMD, OMP, and MPI? What are the differences between them?
ASSIGNMENT Goal of this assignment Distributed parallel computing SIMD using vectorized data Symmetric Multiprocessing using OpenMP Distributed Memory using Message Passing Interface (MPI) Problem Statement Given the following algorithm doing matrix multiplication, implement multiples variations using different types of parallel processing we saw in class: SIMD, OMP, MPI, and OMP+MPI. for (i = 0; i […]
Why are some device drivers not compiled into the kernel? What four conditions must be present for a deadlock to occur?
IT Question Why are some device drivers not compiled into the kernel? Most if not all desktops do not do a thing for preventing, avoiding, or detecting deadlocks. Explain why this is not a good design decision. What four conditions must be present for a deadlock to occur? Explain (Lecture 14) Mutual exclusion Hold and […]
What algorithm would you create to find a door and what may be behind it? If you find the cash, what steps will you take to find the correct door out of the room and avoid the deadly spikes?
ASSIGNMENT Background: The town recluse has invited you to dinner at his lavish century-old Victorian mansion outside of town; the dress is formal. When you arrive, you greet and are greeted by the other guests and house staff. After socializing, dinner begins in the dining room underneath the sparkling crystal chandelier with dishes that dazzle […]
Using your sets A and B along with what you just outlined to prepare, determine an algorithm that you can use to see whether A ⊆ B.
Post 1: Initial Response Imagine you are responsible for your organization’s analytic tasks, and you are currently brainstorming how to query a relational database of marketing information for the organization. You want to test your understanding of how you might relate the database tables with the use of set theory, and particularly subsets. To carry […]