Language:EN
Pages: 3
Words: 92053
Rating : ⭐⭐⭐⭐⭐
Price: $10.99
Page 1 Preview
and streets that run north and south

And streets that run north and south

Questions 1

An example code for Classifier decision fusion technique

R1

values from 1 through 8 , and report its accuracy for each branch.

μ

) of the following form:

and

b

L

- (infinity) norm criterion as your stopping conditions.

∈R

2

of

N

2

X

linearly onto another space spanned by the principal components, what is the maximum percentage of total variance that can be explained by the two principal components together? Justify your answer.

c[0…n−1]

. The function returns an array of

C

,

z

]

) needs to return the array ["x", "y", "z", "x"].

Questions 8

In this question we get a string consisting of digits

4−g,h,i

5−j,k,I

1. [10 points] The function count_words gets a string phone_number, and returns the number of distinct words that can be constructed from this phone_number. int count_words(const char* phone_number); For example - count_words ("238") needs to return 27. - count_words ("2345677") needs to return 3888. • count_words("7777777777") needs to return 1048576.

Only asking to write a Java method as described, not a complete program or class.

Questions 11

String Boolean methods.

Using replace method, case conversion and ASCII code conversion.

The character at position 0.

The characters from position 5 to position 11.

print(myString[-23:-17])

In the same trinket file, include statements to find out whether:

family

wish

in variable myString.

What is the difference between find method and index method?

i. In the blank trinket given below, write a program to replace substring in a string. User enters three string values: myString, subString and repString. The subString in myString is replaced with repString.

In the same trinket file, write statements to convert all the characters in myString to:

In the same trinket file, convert the character extracted in (iii) to ASCII code and print the result.

Programs using string split() method.

{1,3,6,8,100}

, the output should be 6 - If the tree consists of the numbers

{5,8,10}

, the output should be 8. If the number of nodes is

n

is even, the function returns

A[(n−1)/2]

. int get_median(BST_t* tree);

//

This is the interface for the class Employee. //This is primarily intended to be used as a base class to derive //classes for different kinds of employees. \#ifndef EMPLOYEE_H \#define EMPLOYEE_H \#include using namespace std; class Employee \{ public: Employee( ) ; Employee(string the_name, string the_ssn); string get_name( ) const; string get_ssn( ) const; double get_net_pay ( ) const; void set_name(string new_name); void set_ssn(string new_ssn); void set_net_pay(double new_net_pay); void print_check( ) const; private: string name; string ssn; double net_pay; \} i \#endif //EMPLOYEE_H //DISPLAY 15.6 Implementation for the Derived Class SalariedEmployee //This is the file salariedemployee.cpp. //This is the implementation for the class SalariedEmployee. //The interface for the class SalariedEmployee is in

"\n cout

()≪

end; cout

≪"

Dollars\n"; cout

\n

′′

get_ssn(

salary

\n

′′

and

50%

Revenue= =($T$8+($T$9*F13))

Cost= =F13*$R$13

Use binary constraints and linking constraints to find solutions that minimize travel distance and maximize profits. I don't think it's connected because there's a problem with the duration or cost. Please help me

Questions 18

and Qnot will be single bit outputs. Initially set the D flip-flop to 0 and the Reset_

N

input is 0. 9. Press Ctrl-K. You should see the clk changing. Pressing Ctrl-K again to stop the simulation. Note that even though the clock is changing,

Q

input to 1 and press Ctrl-K again to restart the simulation. 11. Using the poke tool, change the input on

D

. Figure 4: DFF changing inputs NOTE: Sometime, you will click too close to a rising edge and the input won't change until the next rising edge. This is normal. Part 2: Simulate a JK and T flip-flop built using a D Flip-Flop 1. Add new circuits to your design. 1 each for the JKFF and the TFF. Part 2.1 T Flip-Flop 1. Using the circuit you created for a DFF (Part 1 step 1), create a T flip-flop. 2. Simulate it using an O'scope as shown above. Part 2.2 JK Flip-flop 1. Do the same two steps as part

2.1

Step

Instructions

2

You will create a form to manage the data in the Registration table. Use the Form tool to create the form and then modify the form as required. You will also remove the layout control from the form so that the controls can be repositioned freely.

5

4

5

6

0

8

Questions 21

Problem 2: Fast k-NN in 1D. In Problem 1, even if we use quickselect, we need to do a whole pass over the training dataset for each test point. This means that it requires

kNN

in millions of test points. One way to go about this is preprocessing the training data. Suppose input data is 1-dimensional floating numbers i.e. X_train is a list of numpy floats. If you sort X_train, you can run k-NN in logarithmic time via bisection search. Your task is to implement

test by first sorting X_train,

k

-NN over

Y

test is a single input,

Y

Questions 23

1. Convert the following numbers into Ilexadecimal. Show the steps of your work. (4 marks) a.

178

10

b.

1) Order of approximation for numerical differentiation methods Consider the following finite difference approximations a)

h

(x))

(backward difference for

f

f(x+h)−f(x−h)

d)

h

f

′′

)

. By hand, calculate the analytical value of

f

′′

showing

h

( or

f

becomes small. Compare with the theoretical order of approximation for each method.

Questions 25

Ex3. Returning a list before

a

(first occurrence), and then returns a list with all the nodes (up to nodes) right before that node. If the value

v

a

b

, and returning a scalar value that is the result of applying the rectangle rule to the function

f

are the limits of integration. trapezoid_rule : a function taking arguments f,a,b and

n

intervals. The inputs a and

b

, with

n

is even, and raise an exception if it is not even.

Questions 29

The following Item interface and getAllItems function are in core.ts that you will need to write your codes

export interface Item {

}

export function getAllItems(): readonly Item[] {

id: '101',

title: 'PS5 Router',

id: '307',

title: 'Hello Melody',

id: '299',

title: 'Acelook',

id: '2991',

title: 'Gitch 1',

id: '2992',

title: 'Gitch 2',

id: '2993',

title: 'Gitch 3',

id: '2994',

title: 'Gitch 4',

id: '2995',

title: 'Gitch 5',

id: '2996',

title: 'Gitch 6',

id: '2997',

title: 'Gitch 7',

id: '2998',

title: 'Gitch 8',

Specification of product catalog

The product catalog should allow the user to

The shopping cart should allow the user to

view the items in the shopping cart (title, quantity)

Marking

Functional requirements

Make your interface user-friendly and visually attractive. You may implement additional features for this purpose, e.g., animations, paging, etc.

Questions 30

shows that the

10

Questions 32

Suppose we are using the RSA public scheme to generate dual signature in the SET protocol. Given p = 7, q = 17, n = 119, the public key of the gateway is 5, the public key of the buyer is 11. We use a simple way to calculate H(m), i.e., H(m) = m mod 64, and 𝐻𝐻(𝑚𝑚1)||𝐻𝐻(𝑚𝑚2), i.e., 𝐻𝐻(𝑚𝑚1)||𝐻𝐻(𝑚𝑚2) = (𝐻𝐻(𝑚𝑚1) + 𝐻𝐻(𝑚𝑚2)) mod 64. Suppose message size is 6 bits, m1= 10, m2 = 15. The ⊕ takes two inputs with 6 bits.

7. [3 points] Would a stack (A) or queue (B) be more efficient for an undo button in a text editor [3 points] Would a stack (A) or queue (B) be more efficient for a web server connection manager [3 points] Would a stack (A) or queue (B) be more efficient for a breadth-first search [3 points] Would a stack (A) or queue (B) be more efficient for a depth-first search

Questions 34

Warning: Students are members of a learning community committed to the search for knowledge and truth. Essential to that search is the faithful adherence by all students to the highest standards of honesty and integrity. A grade of “0” or “F” will be assigned to assignments on which cheating, plagiarism or any other form of academic dishonesty is committed or determined to have occurred. Using source code for your assignments from anywhere is considered plagiarism/cheating and is therefore prohibited. For details, see Wright State University Student Handbook under “Academic Dishonesty”.

You must not attempt to get help from external sources such as online sites that offer solutions. Any submission for grading must be your own work. You must not copy from others or allow your work to be copied. We will check for similarities of code. Any violation will result in your receiving zero for this assignment. No exception.

Part I. Determine Locations with the Maximum Available Bandwidth

Alice lives in a city where there are a lot of coffee shops with Wi-Fi. In the city, there is one coffee shop at every intersection of streets. Specifically, the city has M (1<=M<=30,000) streets that run east and west, and N (1<=N<=1,000) streets that run north and south. The distance between consecutive parallel streets is 1 meter (it is a very compact city).

On the first line of input, you will be given the integer M, the number of east-west streets. On the second line of input, you will be given the integer N, the number of north-south streets. On the third line of input, you will be given the integer K, the number of coffee shops with a wireless network.

On the next K lines, you will have 4 integers per line. The first integer, x, on each line represents the north-south street on which the coffee shop is located, where 1 <=x<=N. The second integer, y, on each line represents the east-west street on which the coffee shop is located, where 1<=y<=M. The third integer, R, on each line represents the radius of the wireless network from this particular coffee shop. The fourth integer, B , on each line represents the bitrate of the wireless network from this particular coffee shop.

3

5

SAMPLE OUTPUT:

12

DSA signature works as follows: Key generation • Select two prime numbers (p,q) such that q | (p-1) • Choose g to be an element in Zp * with order q • Let α be a generator of Zp * , and set g = α(p-1)/q mod p • Select 1 ≤ x ≤ q-1; Compute y = gx mod p • Public key: (p, q, g, y) • Private key: x Signing message M: • Select a random integer k, 0 < k < q Compute r = (gk mod p) mod q s = k-1 ( h(M) + xr) mod q • Signature: (r, s)

(a) Explain how the signature verification can be conducted by the receiver; (5’)

(a) Explain what the price slippage is in the AMMs mechanism in DeFi. Do we have the price slippage in the order book mechanism? Show your reasons.

(b) What are the needed conditions for an attacker to launch the sandwich attack successfully?

using namespace std;

int main()

cin>>s;

while(s!='0'){

cout<<"You have entered : "<<str;

return 0;

which is an

n

,r

i

i

(l

i

)

represents the set of integers between

r

i

5,6,7,8

. Define the intersection of two 2-tuples as the integers that are members of both tuple ranges. For example, the intersection of

6,7,8

whereas the intersection of

5,6,7,8

. For this problem I want you to determine the two intervals with the largest intersection. You may assume that

values for each tuple. (a) Explain the naive approach to compute the largest intersection by computing the intersection between every pair of tuples. What is the run time of this approach? (b) Develop a divide-and-conquer approach to this problem that runs in

Write an Oz program which returns the first element of a list and the last element of that list. For example, if the input is [2 ~5 3 ~1 6 ~3 9 4], the output should be 2#4, if the input is[4 ~2], the output should be4#~2, and if the input is [2], the output should be 2#2.

Questions 41

2

nd

10

Part A: Demonstrate an understanding of parallelism, concurrency, and multithreading in

C++

c. Show the content of

PC,AC

Questions 44

Test designs (Black box testing)

b. Identify whether a given string contains any numeric characters.

c. Identify whether a given string is a valid number or not.( e.g. “ 5..5” is not a valid number ;” 5.5” is valid, “-^5” is not a valid number etc.)

EMPLOYEE \begin{tabular}{|l|c|l|c|c|c|c|c|c|c|} \hline Fname & Minit & Lname & Ssn & Bdate & Address & Sex & Salary & Super_ssn & Dno \\ \hline John & B & Smith & 123456789 &

1965−01−09

& 3321 Castle, Spring, TX & F & 25000 & 987654321 & 4 \\ \hline Jennifer & S & Wallace & 987654321 &

1941−06−20

& 5631 Rice, Houston, TX & F & 25000 & 333445555 & 5 \\ \hline Ahmad & V & Jabbar & 987987987 &

1969−03−29

\\ \hline Administration & 4 & 987654321 &

1995−01−01

\\ \hline 123456789 & 2 &

7.5

\\ \hline 453453453 & 2 &

20.0

\\ \hline 333445555 & 10 &

10.0

\\ \hline 999887777 & 10 &

10.0

\\ \hline 987654321 & 30 &

20.0

&

1986−04−05

& Son \\ \hline 333445555 & Joy &

F

&

1942−02−28

& Son \\ \hline 123456789 & Alice &

F

&

1967−05−05

In C

Matrix.c

if (freopen(argv[1], "r", stdin) == 0)

oops("Cannot open the input file.\n", -1);

// the real magic happens in here

pthread_t **tids1 = multiply(a1, b1, c1, m1, k1, n1);

printf("\nMATRIX A1\n");

displayMatrix(a1, m1, k1);

printf("\nMATRIX A1 x B1\n");

displayMatrix(c1, m1, n1);

printf("\nMATRIX B2\n");

displayMatrix(b2, k2, n2);

return 0;

}

// TODO: implement

free(cell);

// and used by the caller

// should call the function loadMatrix(int ***matrix, int m, int n)

}

void loadMatrix(int ***matrix, int m, int n)

{

// TODO: implement

for (int i = 0; i < m; i++)

for (int j = 0; j < n; j++)

cell->j = j;

cell->k = k;

}

join(tids, m, n);

//alloc overall space

pthread_t **tids = (pthread_t **)malloc(sizeof(pthread_t *) * m + sizeof(pthread_t) * n * m); //tids is an m by n matrix

return tids;

}

if (pthread_join(tids[i][j], NULL) != 0)

oops("Cannot join thread\n", -2);

}

void free_tids(pthread_t **tids, int m)

Matrix.h

#ifndef __MATRIX_MULT_H_

#define oops(errmsg, err) { perror(errmsg); exit(err); }

// struct for passing indices to the threads

int k;

int **a;

void allocateAndLoadMatrices(int ** *, int ** *, int ** *, int *, int *, int *);

void loadMatrix(int ** *, int, int);

void join(pthread_t **, int, int);

void displayMatrix(int **, int, int);

1 4

2 5

1 5

2 6

---------------

Output

1965−01−09

& 731 Fondren, Houston, TX & M & 30000 & 333445555 & 5 \\ \hline Franklin & T & Wong & 333445555 &

1941−06−20

& 291 Berry, Bellaire, TX & F & 43000 & 888665555 & 4 \\ \hline Ramesh & K & Narayan & 666884444 &

1969−03−29

& 980 Dallas, Houston, TX & M & 25000 & 987654321 & 4 \\ \hline James & E & Borg & 888665555 &

1995−01−01

\\ \hline Headquarters & 1 & 888665555 &

7.5

\\ \hline 666884444 & 3 &

20.0

\\ \hline 333445555 & 2 &

10.0

\\ \hline 333445555 & 20 &

10.0

\\ \hline 987987987 & 10 &

20.0

\\ \hline 987654321 & 20 &

1986−04−05

& Daughter \\ \hline 333445555 & Theodore &

F

&

1942−02−28

& Spouse \\ \hline 123456789 & Michael &

F

&

1967−05−05

& Spouse \\ \hline \end{tabular}

100.0

lbs Made of: Pine 1 Table Item Number: 11112 Weight:

80.5

Teak wood rejected. tablel.getwood(): Oak Negative weight rejected. bed1.getWeight():

}

; doub

}

; Furniture [] furniturega1lery = new Furniture[tab]ewtData. 1ength + bedwtData. 1ength]; System. out. print 7 (" Adding Tabledata..."); int index

k++

) \{ try\{

Questions 53

Write an update statement to remove the term field from documents that the value of the term filed is 3.

{

public static void main(String args[])

original = in.nextLine();

int length = original.length();

else if (!Character.isLetterOrDigit(c[j])) j--;

else if(Character.toLowerCase(c[i++]) != Character.toLowerCase(c[j--]));

c. Randall wants the countdown clock to display leading zeroes when the minsLeft or secsLeft values are between 0 and 9. The addLeadingZero.) function has been provided for you to add these zeroes if necessary. Create a new variable named minsstring and set it equal to the value returned by the addLeadingZero() function using minsLeft as the parameter value. d. Call the addLeadingZeron function again using secsLeft as the parameter value and store the result in the secsstring variable. e. Within the element with the ID minutes, change text content to the value of the minsString variable. Within the element with the ID seconds, change the text content to the value of the secsString variable. f. Randall has supplied you with a function named checkTimer() that will check whether there is any time left to submit the order. Add a command to call this function. The function has no parameters. Explore g. Use the decrement operator to decrease the value of the timeLeft variable by 1 . Explore 9. Scroll back to the top of the file and, directly below the statement that declares the timeLeft variable, insert a command to run the countdown() function every second. Store this timed command in a variable named clockld. 10. Scroll back down the file and, directly below the countdown0 function, insert a function named stopGockO. The purpose of this function is to stop the clock once the time to submit the order has run out and to notify the user that the time has expired. The function has no parameters. Add the commands specified in Steps

a

(Order Expired), directly before the end of the page element with the ID TimeHead. Explore b. Use the clearintervalo method to clear the timed command stored in the clockID and stop it from continuing to run. 11. Document your code with descriptive comments. 12. Save your changes to the file and then open ph pay.html in your browser. Verify that a 15 -second countdown commences once the page is loaded and continues counting down to zero. Further verify that seconds values between 0 and 9 are displayed with leading zeroes. 13. Return to the ph_clock.js file in your editor. Change the initial value of the minsLeft and secsLef variables to 30 and 0 respectively. 14. Save your changes and reload ph_clock.html in your browser. Verify that the countdown clock now starts from 30 minutes and counts down every second to the end of the time allotted for the order. New Perspectives on HTML 5 and CSS3, 7th Edition Tutorial 9 Case Problen 4 Countdown Clock for Ticket Ordering Author: Biruk Hailu Date: Novenber 25,2072 Filenane: ph_clock.js

∗f

b

to the function. a. Use the insertAdiacentHTMLO method to insert the following HTML code

EMPLOYEE \begin{tabular}{|l|c|l|c|c|c|c|c|c|c|} \hline Fname & Minit & Lname & Ssn & Bdate & Address & Sex & Salary & Super_ssn & Dno \\ \hline John & B & Smith & 123456789 &

1965−01−09

& 3321 Castle, Spring, TX & F & 25000 & 987654321 & 4 \\ \hline Jennifer & S & Wallace & 987654321 &

1941−06−20

& 5631 Rice, Houston, TX & F & 25000 & 333445555 & 5 \\ \hline Ahmad & V & Jabbar & 987987987 &

1969−03−29

\\ \hline Administration & 4 & 987654321 &

1995−01−01

\\ \hline 123456789 & 2 &

7.5

\\ \hline 453453453 & 2 &

20.0

\\ \hline 333445555 & 10 &

10.0

\\ \hline 999887777 & 10 &

10.0

\\ \hline 987654321 & 30 &

20.0

&

1986−04−05

& Son \\ \hline 333445555 & Joy &

F

&

1942−02−28

& Son \\ \hline 123456789 & Alice &

F

&

1967−05−05

stopwatch.py

import time

el = time.clock() - self.t;

return el

self.t = time.clock();

def elapsed(self):

class VideoGameSearchEngine:

def __init__(self,fileName):

return;

def linearsearch(self,searchterm,colindx):

if any(searchterm in s for s in self._data[i]):

count=count+1

for x in self._data:

print(*x, sep='\t')

usersech = input("Enter Search Term(s):")

v = VideoGameSearchEngine('video_game_data.csv');

usrch = input('Do you want to continue(y/n)')

if(usrch == 'y'):

if __name__ == "__main__":

main()

b) Iterate in both dimensions from 1 to DIM inclusive

- - - X−−

−−−X−−

−- - X−−

2. Display the American flag using a nested loop of these dimensions:

=

and - to represent stripe colors 3. Display an

x

0

0

x

0

x

0

0

x

0

x

0

0

x

0

x

0

0

x

0

A

and

B−

numbers of times. For example, if

A+A

+

B

is a variable that you keep track of. - If you make no progress. Why don't you implement the "algorithm" in CLanguage and use what you learn from the "Addition" example, demonstrated in detail in the lecture and lab, to come out with the corresponding machine code for this task.

1955−12−08

& 638 Voss, Houston, TX & M & 40000 & 888665555 & 5 \\ \hline Alicia & J & Zelaya & 999887777 &

1962−09−15

& 975 Fire Oak, Humble, TX & M & 38000 & 333445555 & 5 \\ \hline Joyce & A & English & 453453453 &

1937−11−10

& 450 Stone, Houston, TX & M & 55000 & NULL & 1 \\ \hline \end{tabular} DEPARTMENT DEPT LOCATIONS \begin{tabular}{|l|c|c|c|} \hline \multicolumn{1}{|c|}{ Dname } & Dnumber & Mgr_ssn & Mgr_start_date \\ \hline Research & 5 & 333445555 &

1981−06−19

\\ \hline \end{tabular} \begin{tabular}{|c|l|} \hline Dnumber. & Dlocation \\ \hline 1 & Houston \\ \hline 4 & Stafford \\ \hline 5 & Bellaire \\ \hline 5 & Sugarland \\ \hline 5 & Houston \\ \hline \end{tabular} WORKS ON PROIECT \begin{tabular}{|c|c|c|} \hline Essn & Pno & Hours \\ \hline 123456789 & 1 &

40.0

\\ \hline 453453453 & 1 &

10.0

\\ \hline 3334455555 & 3 &

10.0

\\ \hline 999887777 & 30 &

35.0

\\ \hline 987987987 & 30 &

15.0

\\ \hline 888665555 & 20 & NULL \\ \hline \end{tabular} \begin{tabular}{|l|c|l|c|} \hline \multicolumn{1}{|c|}{ Pname } & Pnumber & Plocation & Dnum \\ \hline ProductX & 1 & Bellaire & 5 \\ \hline ProductY & 2 & Sugarland & 5 \\ \hline ProductZ & 3 & Houston & 5 \\ \hline Computerization & 10 & Stafford & 4 \\ \hline Reorganization & 20 & Houston & 1 \\ \hline Newbenefits & 30 & Stafford & 4 \\ \hline \end{tabular} DEPENDENT \begin{tabular}{|c|l|c|c|l|} \hline Essn & Dependent name & Sex & Bdate & Relationship \\ \hline 333445555 & Alice & F &

1958−05−03

& Spouse \\ \hline 987654321 & Abner & M &

1988−12−30

& Daughter \\ \hline 123456789 & Elizabeth &

Questions 62

there's an errors for my C++ code. please fix it ASAP. your help greatly appreciate.

1955−12−08

& 638 Voss, Houston, TX & M & 40000 & 888665555 & 5 \\ \hline Alicia & J & Zelaya & 999887777 &

1962−09−15

& 975 Fire Oak, Humble, TX & M & 38000 & 333445555 & 5 \\ \hline Joyce & A & English & 453453453 &

1937−11−10

& 450 Stone, Houston, TX & M & 55000 & NULL & 1 \\ \hline \end{tabular} DEPARTMENT DEPT LOCATIONS \begin{tabular}{|l|c|c|c|} \hline \multicolumn{1}{|c|}{ Dname } & Dnumber & Mgr_ssn & Mgr_start_date \\ \hline Research & 5 & 333445555 &

1981−06−19

\\ \hline \end{tabular} \begin{tabular}{|c|l|} \hline Dnumber. & Dlocation \\ \hline 1 & Houston \\ \hline 4 & Stafford \\ \hline 5 & Bellaire \\ \hline 5 & Sugarland \\ \hline 5 & Houston \\ \hline \end{tabular} WORKS ON PROIECT \begin{tabular}{|c|c|c|} \hline Essn & Pno & Hours \\ \hline 123456789 & 1 &

40.0

\\ \hline 453453453 & 1 &

10.0

\\ \hline 3334455555 & 3 &

10.0

\\ \hline 999887777 & 30 &

35.0

\\ \hline 987987987 & 30 &

15.0

\\ \hline 888665555 & 20 & NULL \\ \hline \end{tabular} \begin{tabular}{|l|c|l|c|} \hline \multicolumn{1}{|c|}{ Pname } & Pnumber & Plocation & Dnum \\ \hline ProductX & 1 & Bellaire & 5 \\ \hline ProductY & 2 & Sugarland & 5 \\ \hline ProductZ & 3 & Houston & 5 \\ \hline Computerization & 10 & Stafford & 4 \\ \hline Reorganization & 20 & Houston & 1 \\ \hline Newbenefits & 30 & Stafford & 4 \\ \hline \end{tabular} DEPENDENT \begin{tabular}{|c|l|c|c|l|} \hline Essn & Dependent name & Sex & Bdate & Relationship \\ \hline 333445555 & Alice & F &

1958−05−03

& Spouse \\ \hline 987654321 & Abner & M &

1988−12−30

& Daughter \\ \hline 123456789 & Elizabeth &

Questions 64

Create a Monte Carlo simulation.

a =1, b = 0.5, c = 0;

so in math terms f(x) = (a * x * x ) + ( b * x ) + c

2) call the Monte Carlo Simulation function with the number of darts to throw starting at 10 and then use powers of 10 untill you get to 10 million,

( 10, 100, 1000, 10000, 100000, 1000000, 10000000 ) . I expect to see this as a for loop.

// to get RAND_MAX do

#include <stdlib.h> // needed to get RAND_MAX

7) I will show my output. I expect your program to calculate these values or values like these. Do not hard code, etc.

8) here is a example of the expected output.

Number of total darts thrown : 10000 number under curve : 2912 area under curve = 0.5824

Number of total darts thrown : 100000 number under curve : 28987 area under curve = 0.57974

3) could we distribute this work load across 10 computers easily ?

4) do your last three lines show the answer getting larger, then smaller then larger? How confident are you that we have the needed accuracy?

and another vector

y

. A factorial of a number is given by:

F(n)=n

n

into R0, i.e., RAM[0]. - The factorial result

300×300

pixels. The image depth is 3 (for the

b

be the bias vector. (i) What are the dimensions of

8×8

kernel, how many parameters will the layer have? Show your working for full credit. (iii) The gradient optimization method used evaluates how much the output

Questions 68

You implement a network ensemble method to identify the letter

i

)

2

=

k

+

ϵ

=

k

k−1

c

, and variances

Questions 70

You will need to show your working for this question. If you would like to upload an image of your solution (e.g. a photo of hand written workings or e-writing) embed an image using the Embed Image icon from the toolbar. Scenario sWin Pty Ltd is a growing company that needs a new subnetting plan. They hope to launch to 20 new locations. The sWin CIO has asked that each subnet should host at least 800 devices. sWin has obtained a network address of 64.92.0.0/17. As this address needs to be subnetted further, the

15IP

addresses following the Router Pool are reserved for servers. - Wireless Access Ports: The next

9

is a elementwise multiplication.

i

o

t

t

)

+U

)

=σ(W

+U

(o)

=tanh(W

(c)

(c)

h

t

t

=o

)

if

f

t

2A→B

. A generic model for the reaction rate is:

=−kC

a

, the rate constant is

A

as a function of

ln(k)

, and visualize them in corner plots. (Hint: 1: Use values from 1 as the prior knowledge. 2. It is similar to the in-class example). [2] Imports import nunpy as np

){

if (!cur) \{ cur

(n==2){

return

+1/(n∗(n−1)))

; \} ? To prevent an infinite loop in a production system. Write a program doing the same calculation without recursion. Please be reminded that a while loop is also considered not good in a production system.

n

between 5 and 50 ) and provide a feedback report about the exam. Your program will take data from the user or a file, depending on the user's choice. If the user chooses to input the data manually, then the input line contains the exam's number of questions (n) followed by a space and then an

n

-characters, which represents the correct answers. Then the following lines represent each student's response and begin with the student ID, followed by the answers. Your program is to produce an output file containing the answer key, each student's ID and each student's score as a percentage and then information about how many students missed each question, class average and student percentage with grade letter. Here are short sample inputs and outputs. Input GENG230 multiple choice exam grader 1 - Input data manually 2- Input data from a file. 3- End. Enter your choice

m

nodes into one (30 points) Write the member function collapse_m_nodes(int m), which will collapse the first m nodes into one node that contains the average of their values. The function does the same with the next

O(n)

time. You are allowed to use an extra (temporary) data structure in your implementation, but you will get extra

A. Two particles (point charges) are on the x-axis as shown below. Particle 1 charge

Q1 = +1.0 C and Q2 particles = -3.0 C separated by L= 10 cm. If particle Q3 the charge is unknown

the magnitude is the same, namely 0.9 µC (see the picture below). With an electrostatic constant k = 9.9

x109 Nm2C-2, determine the resultant electric field strength (E) at point C.

and in Big O notation.

Questions 78

p

3.142

Questions 79

2

8610+(−57

10

4. Draw a simple diagram with a brief explanation that shows the structure of a Von Neum? machine. (7 marks) 5. Briefly explain TWO (2) steps in the Instruction Cycle ( 10 marks). Tins. Refer to chapter 4, Buses.

Questions 81

c. the electric current through each resistor

Questions 82

This class will keep track of each players symbol that they are going to use and the number of wins that they have.

symbol - a char that only letters or a space but no other ASCII characters

A public final char, DEFAULT_SYMBOL, which you can choose.

plus any others that may be needed

void resetWins(), which will set the wins back to 0 for a new series of games.

Foothill class

char askUserForSymbol(), will ask the user what the symbol for will be for that player. Don't allow the method to return until a valid capital letter is entered. No other ASCII values are allowed. Call this separately for each of the two players. Enter one bad value on purpose.

void resetBoard(Player[][] , Player ), which is used at the start of any game to fill the board with the default Player.

There will be 5 games played, after which display the number of wins for each player. During a game, have one player move and check to see isWin() and if not, then check isDraw() to see if the other player can go. Display the board and then have the second player go and check both again. Loop back to the first player and so on. When the game is over, display who won or if there was a draw. Don't forget to reset the board after the game is over before the next one begins.

Here's a sample output.

--------------

| | | |

--------------

Enter a row (0, 1, or 2) for player C: 1 (enter)

| | C | |

--------------

--------------

| | | |

--------------

Enter a row (0, 1, or 2) for player C:

--------------

| Z | C | Z |

Game 2 starting:

--------------

| | | |

--------------

Z player won!

Number of wins for player C: 3

[0×100100F0]<=$rs+$rt+signEx

\& Perform minimum number of modifications and all previous instructions must continue to work. Do not insert any unnecessary component to the datapath. Do not insert any adders or ALUs to the datapath. Do not increase the number of inputs for the ALU or Adders in the datapath. Show your solution drawing on the cheat sheet front side and send that page after scanning. b. (10pts) Assume the opcode of the instruction is 001101 . Then, show the Logic which generates an addm signal which becomes 1 when addm comes.

Questions 85

To provide you with an opportunity to seek and discuss feedback and any reactions to the presentation from participants and relevant stakeholders. Access to peers. This activity will need to be observed. Select 2-3 of your peers who were audience members for your presentation in Activity 2A, and seek feedback from them using one of the following methods: Feedback sheet Survey/questionnaire Focus group interview. Discuss this feedback with your peers, with the aim of understanding their opinions. Note: where feedback sheets, surveys, or questionnaires are used, these should be attached to your workbook for assessment.

456=1111 b

. 7. Summarized using your own words, the difference between Direct Mapping, Associative Mapping, and Two-way Associative Mapping in Cache Memory organization. (15 marks)

B==89

-

F=69

Remember, each section needs to have its own separate average. You output should be your python source file (.py file) and a screenshot of your output

Provided framework

Some codes are provided for you. It describes the data structure of product items of the e-shop and contains a small set of testing data.

description: string;

price: number;

const shopItems = [

{

},

{

},

{

},

{

},

{

},

{

},

{

},

{

},

{

},

{

},

{

}

] as const;

Note: no repeated item is allowed

Specification of shopping cart

reset the entire shopping cart

calculate the total amount of the order

50%

Design

dataset that i will provide in (Weka) and please

provide screenshots for everything needed

which is highly correlated to the class label.

Support your discussion with a visualization of

4. Inspect the visualization of the obtained

decision tree, and discuss:

this is the data set i want to be used :

https://files.fm/u/zhj4sva2j

public String blood_pressure(){

String status = rand.nextInt(100) < 50 ? "low" : "ok" ;

You must run and provide output on the following main program (without any changes to the program).

You are not allowed to make any changes to the code given below

}

}

Your app must include: • A clear and helpful user interface that helps the user understand how to interact with the app • Logically and syntactically correct code to respond to the user’s actions and display the desired results • A separate class file, Product.cs, that contains your Product class • A way for the user to enter/store Product information • A way for the user to interact with / change properties of the stored Product object • Error handling techniques, such as try/catch, to ensure that the program can recover from errors properly o Feedback to the user regarding errors and failed operations • Code should be commented, tabbed/formatted correctly, and well organized • Objects and variables should be named appropriately o Follow the naming conventions outlined in the document “Naming Conventions in C#” (found in Blackboard Course Documents) o XAML control names must include appropriate prefixes

Questions 92

(green), Z (red). Your Java program should randomly choose a tetromino shape, a random color for this shape, and a random location within the frame, and displays it on the screen. Then, the program can terminate after a while or wait until the user closes the window. - Create a TetrisViewer class - Create a TetrisComponent (should include a method paintComponent and a method setTetromino(/* shape, color */). - In the TetrisViewer class, randomly choose a tetromino and its color (use java.util.Random). Set this information in the TetrisComponent. Hint: You will use RGB color system, so you can create three random integers between

0−255

coordinate point)). ** You will be displaying one random tetromino only (do not bother to create more objects in one run) ** We are not developing the whole game, so you should not worry about creating multiple different objects and fitting them on the screen... or other specifications of the Tetris game. Our goal is to create one random object only.

∗∗

Circuit Design and Analysis

Determine the strength of the electric current flowing in a closed circuit as shown above, if

thank you

Questions 95

a) Using ASCII b) Using EBCDIC 3) What is the representation for

−25

2∗pi

3.142∗r∗r

and the circumference is

r

and the circumference is

2∗3.142∗r

F=C+BC+AC+ABC

c)

≪<

map_f

{

return a

map_f f float, float

>({1,2.3,3}

map_f

f

return s + ".";

})≪

, [](string s)

{

{0.5,1.15,1.5}

{

Consider an IT student enrolled in N subjects in Term 2 at APIC. In each subject, the student can obtain a mark between 0 and 100. Write a program that prompts a user to enter the number of the subjects the student enrolled in. Create a function that keeps a running total of the student's marks in the N subjects. The function must return the total marks to the main program, and the main program should display the total marks the student obtained in Term 2. Python

Questions 101

1.3

You are asked to optimize a cache design for the given references. There are three directmapped cache designs possible, all with a total of 8 words of data:

C1

has an access time of 2 cycles,

Questions 103

Q1) [50 points] Consider a Hospital, which has several branches (or units) for different expertise, and patients visit hospitals based on symptoms, as you might know. a) Is this a service-oriented way of reaching a health service? If no, why not? If yes, what is the service here? Explain briefly. b) Considering the service orientation principles, discuss autonomy, reusability, statelessness in this example. c) How could a tightly-coupled solution be for this context? Explain briefly. Q2) [50 points] Consider RailCo case study in class. This time from TLS's point-of-view, apply similar service modeling study to the B2B interface between RailCo and TLS. Explain your steps briefly and Show the 2-layered Service Architecture for TLS.

input

output

E.00000

00015C (program length end address -start address)

Questions 106

Using

b

and return 0 if they are equal,

−1

if

a

Examples: char a[10] = "Hello"; assign(a, "World"); a will have the new value : "World" 3. void concatenate(char a[], char b[], char c[]) concatenates

a

Examples: char a[20] char b[10] = "Hello"; char c

b

between firstindex and lastlndex and assigns the result into

b

Hint: you can use the previous function substring. Examples: char a[10] ="oWo"; char b[20] = "HelloWorld"; char c

(c,b)

returns false

Q2) [50 points] Consider RailCo case study in class. This time from TLS's point-of-view, apply similar service modeling study to the B2B interface between RailCo and TLS. Explain your steps briefly and Show the 2-layered Service Architecture for TLS.

Questions 109

1. We consider trying to draw

Q

3

has no triangles as subgraphs and an edge counting argument similar to that used for

K

4

has

n=16

have to be in Euler's equation? C. The graph

Q

4

Q

4

has

Q

5

n−m+r=2−2h

for the

Questions 112

2. Draw

K

4,4

Questions 114

Hello, if I wanted to validate a math equation using stacks in Java how would I do that?

demonstrate program working with simulation of rolling a 30 sided dice as you see in an intuitive manner. Code in ARM please

Questions 117

<nav class="mobile-nav">

<div id="menu-links"> <a href="index.html">Home</a>

<a class="menu-icon" onclick="hamburger ()">

<div>&#9776;</div>

.mobile-nav a {

color: #fff;

display: block;

}

top: 0;

}

5. In the mobile style rules section, move the style rule for the nav ul selector to the tablet media query, below the comment for the tablet nav area style rules.

6. In the mobile style rules section, delete the style rule for the nav li selector.

11. In the tablet media query, below the comment, Tablet Viewport: Style rule for header content, add a new style rule for the header h1 selector that sets the margin and padding to 0 and the font size to 2em.

12. Open your music folder and create a new subfolder named scripts. Create a new JavaScript file named script.js and save it within your scripts folder. Add a multi-line comment to Lines 1 through 5 that includes your name, file name, and today's date.

if (menu.style.display === "block") {

menu.style.display= "none";

16. In the styles.css file, within the desktop media query, add a new declaration to the nav li a:hover style rule that applies a transform with the value scale (1.2).

17. Save all files. Open index.html in Google Chrome's device mode, select a mobile viewport, and test your hamburger icon on each page.

 Q1 – Round Robin (small quantum)

 Q2 – Round Robin (larger quantum)

1. Create a file labweek110.php and create a txt file name lab110.

2. you need to write a sentence in txt file "Hello how are you ?"and the written text should pe printed out in txt file

#include <iostream>

#include <vector>

int max;

max = v.at(0);

}

return max;

//get input from user

cin >> userInput;

cin >> userInput;

}

int cnt = 0;

for ( i = 0; i < userValues.size(); ++i){

return cnt;

}

/*Call the given functions to get the values from the user, get the max value and

output the number of occurrencdes of that max value*/

Identify at least two modules that will benefit from a white-box testing strategy. Create test cases using the white-box testing methodology to cover the functionality of the chosen modules. Clearly state which modules are tested using the white-box approach.

a. Converting a given string to upper case or lower case.

f. Converting a number which represents a time given in hours to minutes and vice versa.

Questions 122

If you copy paste from other answers. I will report you, all I want is for this algorithm to be written code in python.

Remote Worker’s Overtime Plan: Remote working is becoming more attractive day by day.

According to the rules & regulations of the ABC company: “For each day, you are allowed to complete only one portion of the task in only one overtime working slot.

Once you complete a portion of the task your wage is paid, immediately.

2 1 500

3 1.5 800

i. Design a polynomial-time algorithm that solves the Remote Worker’s Overtime Plan problem on paper by applying the steps of Dynamic Programming and submit it as your project report (30 pts)

ii. Implement an iterative (not a recursive) algorithm based on your design in part(i) (60 pts)

Enter the payment value (in TL) for task portion ID 2 having length 1 hour(s): 500

Enter the payment value (in TL) for task portion ID 3 having length 1.5 hour(s): 800

On Day 2 do task portion with ID 2

The most profitable completion of the assigned task takes 2 day(s).

∗∗

2

) The Partition problem

1

integers, can it be split into two subsets with equal sums? That is, are there subsets

A

, and

a∈A

A={1,2}

and

O(nM)

, where

P=NP

?

1. Declare variables.

2. Declare function setOperator(m).

-- display the result in input field, document.getElementById("result").value = result;

<BODY>

<TR>

<TD></TD>

<TR>

<TD rowspan=2><INPUT TYPE="text" NAME="" size =10 name="fo" id="fo"></TD>

</TR>

<TR>

</TR>

<TR>

<TD><INPUT TYPE="reset" value="Clear"> </TD>

</TR>

Questions 127

(6

+

problem is very similar to the 3PARTITION problem defined on

2

6 PARTITION

of

6n

has exactly the same sum? an algorithm for verifying a certificate, and showing that the verification algorithm takes polynomial time (these descriptions can be brief). Consider the following reduction idea: given some arbitrary set

S

by making 2 copies of every element of

S

S

+

is NPhard. Explain, in detail, why this reduction will not work. c. Consider instead the following reduction idea. Given some arbitrary set

T=100∗

s∈S

S

copies of

T

={0,1,2,3,4,6,T,T,T,T,T,T}

3PARTITION if and only if

S

.

Questions 128

The Program Spec

Player class

A public final char, MIN_SYMBOL, which you can set to A

A public final char, MAX_SYMBOL, which you can set to Z

Constructors that take no parameters (default) and the others with just the symbol parameter. We will always set wins to 0 upon creation. To avoid code duplication make sure that the parameter-taking constructor utilizes the above mutator rather than do anything direct assignments or testing. The default symbol can be ' '.

boolean addWin() will make sure that the wins do not go over the max, but add one if there is room.

Set up a loop to call askUserForSymbol() and make sure that the two players do not have the same symbol. If they do, then give an error message and call for the symbols again for each player. Don't let them out of the loop until the symbols are valid and different from each other.

Use the following static methods to assist the main:

boolean isWin(Player[][], Player), will use the symbol of the incoming player to check each of the possible ways to win. How many ways are there? Don't forget about the diagonal. Return true if they have a win, false if not yet.

boolean isDraw(Player[][]), checks to see if there are any spots still on the board and if not, then it is a draw and returns true. False means that there are still spots on the board.

Sorry that is no good, choose a capital letter. Try again: Z

Game 1 starting:

--------------

| | | |

| | | |

--------------

Enter a row (0, 1, or 2) for player Z: 1 (enter)

Enter a column (0, 1, or 2) for player Z: 2 (enter)

--------------

| | | |

--------------

| C | | |

--------------

C player won!

| | | |

--------------

...

... (after a total of 5 games)

pleaseee do not add or delete anything else pleasee use the simplest way for writing the code

thank you

w

means

a,b,c,d,e

. A. Form the victory matrix

=1

=Aw

i

for enough values of

Questions 131

regular expressions, that the password starts with a letter, includes at least a digit, a special character and its length is at least 7 characters.

#define MSGKEY 75

struct msgform

main()

{

msgrcv(msgqid,&msg,256,1,0);

pint=(int*)msg.mtext;

*pint=getpid();

msgsnd(msgqid,&msg,sizeof(int),0);

db2,3,5,7

Questions 134

Questions 135

I need help with cengage mind tap python program exercise 5.5, 5.7, and 6.1. The previous answers I got did not work. I need someone to write the code and explain how it works. Thanks

Run “ls -la /mnt/Users” and see what the Linux permissions are set to. Does it appear that you should have permissions to all of the folders?

A: It doesn’t look like I have permissions to all of the folders

i. Select one Journal Article based and demonstrate your ability to write a direct quote from the article. The quote selected should demonstrate your understanding of Design Thinking. (0.5 mark)

ii. Describe and justify the overall reason you have selected the direct quote above to support your understanding of Design Thinking. (2 marks)

and

B(9,2)

. Develop a table to connect

A

and

y

were to be switched, derive an expression (with illustrative diagram) for Bresenham's algorithm that connects the new points

A

. Generate a plot for

A

AB

.

First, you choose your favorite Make and Model for a car. For example, you choose Hyundai, Elantra.

Next, you use any of the online used cars markets to manually acquire data about the available offers (Note that the data generation process can be automated using a web crawling bot). You can use, Facebook market, Kifi, or Autotrader websites for generating your data.

• Use data analysis toolbox of excel to train a regression model on the generated data. Your regression model should predict the price of a vehicle based on its mileage

Generate the residuals table, residual plot, and the line fit plot. Make the trend line visible.

An organization is granted a block of addresses with the beginning address 18.29.89.0/26. The organization needs to have 3 subblocks of addresses to use in its three subnets: one subblock of 10 addresses, one subblock of 60 addresses, and one subblock of 120 addresses. Design the subblocks

Questions 141

. The function should insert a new node that contains the value

v

. For strings, that node would be the one with smallest hamming distance from

v

time. Examples (numeric list): after L1.insert_at_closest(4) the list becomes after L1.insert_at_closest(6) the list becomes after L1.insert_at_closest(14) the list becomes note that 15 and 13 have the same distance from 14 , but 15 came before 13 in the list. More examples (string list): Given the list L2: ["abc" "abc abc" "abc xyz" "xyz"] after L2.insert_at_closest("ab") the list becomes ["ab" "abc" "abc abc" "abc xwz" after L2.insert_at_closest("abz abx") the list becomes ["abc" "abz abx" "abc abc" "abc after L2.insert_at_closest("xy1") the list becomes ["abc" "abc abc" "abc xwz" "xy1" / Modified Hamming distance between two strings nt str_hamming_dist(string str1, string str2) unsigned long

i=⊙

Each of the following addresses belongs to a block.

Find the first and the last address in each block.

Q2) (10 points) If the following signal

m(t)=cos(5

is applied to DM system with

T

=0.5v

a) Sketch

(t)

has the four control points

P

=

, and

P

B(

2

Questions 146

distance vector routing.

The program should display a menu that lets the user look up a person’s email address, add a

new name and email address, change an existing email address, and delete an existing name and

a. A function to display a menu.

b. A function to look up a person’s email address.

g. A function to save emails in a file.

h. Write main function with a loop that displays the menu allowing the user to select an

If the user selects invalid operation from the menu, the program prints an error and allows

the user to renter a valid operation; the program continue asking for a valid operation

I will upvote right away!

=== Questions ===

- Write a SQL statement that will list the names of suppliers that have never been supplied a product.

[Please include screen shot of BOTH the code AND the output]

control points

P

,…,P

B(t)=∑

i=0

×B

n,i

⋅t

i

t

, computing the derivative curve

B

n

. With some simple algebraic manipulations, we have the following result for

B

B(t)

yields:

(t)=

B

n−1,i

−P

i

0

0

2

2

2

n

. The above equation reduces to the following:

B

n−1

i

defined by

n

−P

0

−P

1

−P

2

−P

n−1

3

so that it starts at

(5

,

(

at time

t=1

) is equal to

P

0

,P

2

for the Bézier curve

B(t)

. (c) The "first half" of the Bézier curve is the curve

. Express

B

Questions 150

(i) Describe an algorithm for clipping a line against a rectangle. Show that it works using the above three examples (ii) Describe in detail the Cohen-Sutherland algorithm to clip a straight-line segment against a rectangle (iii) Extend the algorithm from part (i) to clip a line against a three-dimensional viewing frustrum. (iv) Describe how to clip a Bezier curve against a screen rectangle.

(−1,2,−3)

, the base is centred at

2. Is it possible for the receiver to send an acknowledgment to the sender about receiving a message in a connectionless communication (e.g., in UDP of TCP/IP)? If yes, how?

3. On the one hand, it is said that binding address for the sender/client process is optional. On the other hand, it is said that any communication in a computer network requires the addresses on both sides of the communication. Are these two sentences contradictory? Explain your answer.

c) Opening Google’s page from a browser

d) Opening Facebook’s app from a cellphone

i) Copy-Paste of a text from MS-Word to MS-Exel

Please choose two to three questions to answer, thank you.

M

which represent the same numbers regardless of their position. - Symbols are placed in order of value, starting with the largest values. - When the higher numeral is placed before a lower numeral, the values of each Roman numeral are added. - When smaller values precede larger values, the smaller values are subtracted from the larger values, and the result is added to the total. - Do not repeat

V,L

, and

M

LC because it is the same as

because it is the same as

V

f) Use these function names in your class: void setRoman(string); bool romanValid(); void romanToPositiveInteger(); void printPositiveInteger() const; void printRoman() const; romanType(); romantype(string); g) Submit your class header file (romanType.h) and implementation file (romanType. cpp). elow is an example of what your output must look like: Enter a roman number or

Q/q

to quit: MDcccLxxxVii The equivalent decimal number of the Roman numeral MDccclxxxviii is 1888 Enter a roman number or

Q/q

to Quit: Hel1o Invalid Roman Digit Enter a roman number or

Q/q

This Questions should be solved in (WEKA)

cause

1. Provide a visual overview of all the attributes in

your dataset.

3. Using the default settings of the decision tree,

report on the performance of your classifier (e.g.

and

2) any interesting observations learned from the

Questions 155

There's an errors for my C++ Code. Please help me to fix it ASAP. THANKS!

vector <string> ProfileID, ProfileInfo, Obesitystatus, DailyCaloriesConsumption;

string nProfileID, nProfileInfo, nObesitystatus, nDailyCaloriesConsumption;

if (inFile.fail())

{

cout << "The file is opened. You may proceed." << endl;

while (!inFile.eof())

getline(ss, substr, ',');

ProfileID; substr;

getline(ss, substr, ',');

Obesitystatus; substr;

}

}

for (int i = 0; i < vectorSize; i++)

{

cout << "\n";

nonExist = false;

}

Questions 156

1. [6 Points] In Chapter 6 , we have discussed two function parameter passing techniques available

void swapReference (int

&a

b=

temp; b a) What is the output of the cout statement 1 above? b) What is the output of the cout statement 2 above? c) Briefly explain your answer to questions (a) and (b)? Part - II 2. [14 Points] Driver's License Exam Grader System The local Driver's License Office has asked you to write a program that grades the written portion of the driver's license exam. The exam has 10 multiple choice questions. Here, are the correct answers:

5.

C

10.D

are the only valid inputs. If user enters invalid input more than three times display the message "GOOD BYE " and exit the program. Use appropriate constants in your implementation. Both arrays: correctAnswers and studentAnswers must be declared in the main program. Submission Instruction (for both Part I and Part II) Submit your homework by following the instructions below: - Submit your Assignment5.cpp file on-line. - Assignment5.cpp should have the following, in order: In comments, the assignment Header. In comments, the answers to written exercises for part one The working

C++

Questions 158

Design a counter using a Raspberry

s

falls within cache capacity. The score is calculated as follows: Implementation of the cache should be optimized on the time complexity of get(key). For example, the average time complexity of get(key) could be constant. For the purpose of implementing the cache, you could assume that common data structures, such as arrays, different types of lists, and hash tables, are available. At the end of the answer, give and explain the computational complexity of

Questions 161

Write a python program to verify a path from 0,0 to 7,7 use # 1 right 2 down 4 left 8 up. The function should take a multidimensional array and a list of moves. the moves should be encoded as a list of integers: 1 right 2 down 4 left 8 up

[15, 12, 10, 5, 15, 5, 9, 15],

[ 5, 4, 13, 3, 8, 8, 14, 6],

#starting position is 0,0

#if the path step is not available at the given position, return the number of valid steps

Questions 162

TCP Client in X86-64 Assembly

TCP Client Requirements:

The TCP Client must be fully written in X86-64 (64 bit) Assembly language

Server will then return the specified number of random bytes back to client. These must be stored in an output file (see note about marking sections within file, below).

Client application will then manipulate these data according to requirements given to each group by your instructor (each team will have different requirements for data manipulation)

The code must be designed around procedures and functions, following standard C Calling Conventions

The program must utilize heap (for data manipulation) and stack for passing arguments and for local variables

Project progression:

Phase 1

Prepare presentation about your project (see Deliverables section).

Code file

As a group, participate in a 5-minute Q&A session with your instructor about the project (right after the presentation).

This will be done in Week 15 during your regularly scheduled labs or theory. Exact schedule will be provided in advance.

The live server will not accept exit command. Any reboots of the server code will have to be requested from instructor.

Deliverables:

Introduction

Inner workings of the product (mainly the data manipulation algorithm)

Peer Review:

Fill out peer review form on MS Forms (accessible via Brightspace)

Questions 164

Based on the following software application design diagram as below: Software application design a) Differentiate the external and internal design. b) Describe with examples an application for architectural design.

from scipy import ndimage

from skimage import measure, color, io

opening = cv2.morphologyEx(thresh, cv2.MORPH_OPEN, kernel, iterations=1)

sure_bg = cv2.dilate(opening, kernel, iterations=2)

ret3, markers = cv2.connectedComponents(sure_fg)

markers = markers + 10

borders = np.zeros_like(img1)

borders[markers == -1] = [0, 255, 255]

axs[0].set_title('Overlay on original image')

axs[1].imshow(img2)

boundaries = []

for x in x_s:

# cv2.imwrite(sumBoundaries)

plt.imsave("sumBoundaries.png",sumBoundaries>2)

In this assignment you will create a simple web application that also has limited nesthul API endpoints. You are welcome to modify it to fit something you prefer, but do not remove any functionalty. If in doubt, just askt You tan see it in action here: Maps

H

b)

F=C+BC+AC+ABC

V. PROJECT SUMMARY Design a code in C on Arduino IDE to be downloaded onto the AT91SAM3X8E microcontroller found on the Arduino Due board. The purpose of this code is to create an ordering system for checking in patients at a physician's office. The system is facilitated with technology to consider emergency cases that need immediate attention. In the normal case, a patient still arriving first presses on a push button to receive a waiting number. On an LCD screen the patient's number will be represented then removed. The LCD will represent the current status of the patient at the doctor's office and his/her number. The status may be taken or lab. Any patient will be with the doctor's for 30 seconds. If a patient needs lab work, then an extra 10 seconds are added on the total visit. Use the rand () function to determine if a patient needs lab work done or not. The value 0 produced for the function indicates no lab work needed and the value 1 indicates that lab work is needed. The status of that patient visiting needs to be updated accordingly to

lab

The coefficient of kinetic friction between m1 and the surface is 0.193. Determine the upward acceleration of m2.

Questions 171

initially and fill in the missing parts of the given table for the circuit given below.

Questions 172

, and T. You are required to generate these blocks by defining separate array for each block or a single array for the all the shapes. The colors of the blocks are varied. This means that block

J

Use the Budget and Actual results below to complete the Calculation Grid. Ensure that you use the "Cell Styles" in Excel formatting to visually identify whether variances are favorable (good) or unfavorable (bad), as per the examples below.

Questions 174

The value of ZAR/USD will be equal to zero when exports are equal to this value

Questions 175

code. For question 4, provide your assessment (at least two paragraphs). For SQL, use Oracle Live SQL (you need to create an account, unless you have one already) or https://sqliteonline.com/.

Questions 176

open ("nonexist. txt", O_RDONLY); file that is nonexistent with the open

(…)

fd

=−1)

: iv. EACCES (13): v. ENETRESET (102): vi. ECHILD (10): vii. EINTR (4): viii. EINVAL (22):

Questions 178

first name

middle name

One Function to set all student’s data. This function receives the data of a student via function parameters.

One function to get (retrieve) all student data. This function should not display on the screen, but it should return the data as output parameters (by reference).

Read from the user and store into the array the data of n students.

Display on the screen the data of n students in a table form. Display a heading row before displaying the data. Example:

Questions 179

What is the value of the slope of this model?

Questions 180

CS3450-01 Operating Systems Programming assignment \#4 Program 4.2: The use of fork, wait, and exec systems calls and Write a program that uses/calls fork() to create a child process. The program an optional simple shell program then calls wait() to wait for the child process to complete its task. Within the program, the newly created child process calls one of the exec() system calls to replace the code it has received from its parents by the Linux/UNIX Assigned: 11/12/2022 cp, which allows the child process to carry out the task of copying a source Due:

4.1

(not really a program; we call it a program only to mean it is separate from the two below programs): a. Run the Linux/UNIX

cp

command). Note: do use same three-paragraph contents for the source file you used in Program

Questions 182

Solve for the product using LHM, Booth Algorithm and Bit-pair recoding technique.

Perform unsigned multiplication. Show the contents of registers C, A and Q after every cycle.

E. 0101 x 1010

x

is (i)luman or (c)iomputer : who plays first

x

or 0 ?

A manufacturer wants to evaluate the MFP. He has ten (10) workers, each working 40 hours per week, for a total of 400 hours, and they produce 8,000 units per week. Assume, the manufacturer pays each worker

$10

after the following code is executed?

x=1;

continue; \}

x+=i;

The project comprises of two tasks;

1. Explore Google Cloud Platform, setup a Virtual Machine in Google Cloud, deploy LAMP (Linux, Apache, MySQL and PHP) Server on that server install WordPress, without using any “Click to Deploy” Images.

The assessment requires you to prepare a report based upon your project and to record a screencast of your Project. To do this you will need to consider the following and specifically add in the body of the report:

Key service offering from Amazon Web Services and Google Cloud Platform.

Comparison of both the Platform EC2 and VM.

The concept of virtualization and elastic resources in AWS and GCP.

Finally, write a conclusion (approximately 200 words) as a summary of your project. This section brings together all of the information that you have presented in your report and should link to the purpose of the assessment as mentioned in the introduction. You can also discuss any areas that have been identified as requiring further investigation and how this will work to improve or change our understanding of the topic. This section does not introduce or discuss any new information specifically, and like the introduction, will be written in complete sentences and paragraphs. No tables, graphs, diagrams or dot points should be included.

Questions 188

, list [1] ,.., list [4]; the statement in line two declares myList to be an array of 11 components, the component type is int, and the components are: myList [2] myList [3],.. myList [12] ; the statement in line three declares yourList to be an array of 14 components the component type is int, and the components are: yourList

[−5]

, yourList [8]. Write a program to test the class myArray. Submit myArray.h along with your test program. please have output match this exactly: Creating: myArray list 1(5) Creating: myArray list2(5) Output list 1: cout Enter 5 integers for list1: 10200300040000500000 After filling list1: 10200300040000500000 set list2 equal to list1: list2 = list1 output list2: cout

: output list3: cout

3≪

end1; Set elements for list 3 : list

[0]=54;

list

"list

end1; list3: 7054015080 Press any key to Exit.

Questions 189

Dor a given graph

G=(V,E)

Questions 191

1. Given that

0x1a38

, and ptr_int

px=&x

, what does

456 ? 3. What does the following code snippet print out? int ar[

]={5,6,7,8}

p;

for

p))

; \} 4. Given that

Questions 192

The Charity wants to keep track of families housed in a new apartment block. Create a class (named Block) with at least three data members to hold the address, the number of apartments and families living in the block. This class should include among other functions, functions to: (i) Add a Family to the Block, (ii) Print out all details for a Block including details of each Family living in it (full marks for overloaded operator

stdio.h

Questions 194

BIS2002 Assessment Brief-T3-2022 Up... Assessment 2: Case Studv Assessment Details: In this assessment event, you must design an information system for the New Zealand CAR HIRE Booking System case study provided at the case study section. This is a continuation of Assessment 1 . This assessment covers the following topics: Use Case Diagram, ER Diagram Class Diagram, Sequence Diagram, Activity Diagram, User and System Interfaces, and System Testing, Deployment, and Maintenance Using the information provided in the case scenario in assessment 1, perform the following: Tasks: 1. Draw Use Case Description for registering accounts and making a booking. 2. Draw Use Case Diagram for registering accounts and making a booking. 3. Identify all entities and their attribute and draw an E-R (Entity-Relationship) diagram. 4. Draw the Class Diagram for the entire system. 5. Draw a Sequence Diagram for registering accounts for the first time. 6. Draw an Activity Diagram for the booking/cancellation of the cars including the stand-by status. 7. Design a data entry screen for entering membership details. The data entry screen should include all the elements required (textboxes, buttons, navigation, etc) 8. Design a car booking screen that includes the date, time, car details, and payment methods. The data entry screen should include all the elements required (textboxes, buttons, navigation, etc). 9. Plan suitable testing and deployment activities (create Test Cases like the sample below):

B -> bSa | b

to a PDA that accepts the same language by final state.

"Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptue""

}

when not found. public static double weightOnPlanet(double weight, int planet) This method calculates and returns the weight of the planet. Testing your program: Test your program thoroughly. Use the input used in the sample output below to create your program output snapshot for your pdf file. ---jGRNSP exect java planetweight This program is for Ac0101 Homework-06. Develped by: Enter a weight on earth. Enter 0 to exit: 89 Enter a valid planet name: mars The weight of the object on the planet Mars is

33.82

Enter a weight on earth. Enter 0 to exit: 54 Enter a valid planet name: JupITEr The weight of the object on the planet Jupiter is 154.98. Enter a weight on earth. Enter 0 to exit: 0 Goodbye! -o-jGRASP: operation complete.

Questions 197

4-4 Chapter 12 ? Write a program that prompts the user to enter the number of candidates in a local election. Using a ? dynamic array, record for each candidate, the last name, and the number of vates received When all candidates have been entered the program will output each candidate's name the number of votes, and the percent of the total votes received by the candidate! Your program should also output the winner of the electionfand on a separate line print the declaration, value, and address of the pointer(s) you used for the dynamic array. A sample output is below: Please make output match this exactly: Enter the number of candidates in the election: 5 Enter candidate's name and votes they received for the 5 candidates. 1: Castro 10000

2:

Value: 00B20CCC Address: 0073FDB0

Questions 201

\begin{tabular}{l|l|l|l|l|l|l|l|l|l|l|l|l|} \hline Midterm Exam & Q1 & Q2 & Q3 & Q4 & Q5 & Q6 & Q7 & Q8 & Q9 & Q10 & Q11 & Q12 \end{tabular} Question -6 \begin{tabular}{|c|c|c|c|c|c|c|} \hline \multicolumn{8}{|c|}{ Use of Formulas - Sum, Average, Counta, Countif, Sumif, \& If } \\ \hline & \multicolumn{2}{|c|}{} & \multicolumn{3}{|c|}{} & \multicolumn{3}{|c|}{} & \multicolumn{2}{|c|}{ Result } \\ \hline Student Name & \multicolumn{3}{|c|}{ Subject } & \multicolumn{3}{|c|}{} \\ \hline Name & Maths & English & Physics & TOTAL & PERCENTAGE & GRADE \\ \hline Alan & 80 & 75 & 85 & 240 & 80 &

00r

& 130 &

?

\\ \hline Eric & 20 & 30 & Absent & 50 &

?

\\ \hline Gail & 10 & 90 & 80 & 180 & 60 &

?

\\ \hline Janice & 10 & 20 & 30 & 60 & 20 &

import java.util.Scanner;

public class Foothill

char Symbol;

Player defaultPlayer = new Player();

Player board[][] = new Player[3][3];

for (int i = 0; i < 5; i++)

while (true)

{

System.out.println(p1.getSymbol() + " plyaer won");

p1.addWin();

System.out.println("It's Draw!");

break;

{

p2.addWin();

{

System.out.println("It's Draw!");

System.out.println("\nNumber of wins for player " + p1.getSymbol() + ": " + p1.getWins());

System.out.println("Number of wins for player " + p2.getSymbol() + ": " + p2.getWins());

{

if (board[i][0].getSymbol() == p.getSymbol() && board[i][1].getSymbol() == p.getSymbol()

return true;

if (board[0][0].getSymbol() == p.getSymbol() && board[1][1].getSymbol() == p.getSymbol()

return true;

}

for (int i = 0; i < board.length; i++)

{

return true;

}

System.out.println("--------------");

System.out.print("| ");

}

public static void makeAMove(Player[][] board, Player p)

System.out.print("Enter a row (0, 1 or 2) for player " + p.getSymbol() + ": ");

row = Input.nextInt();

if (board[row][column].getSymbol() == ' ')

{

}

}

for (int j = 0; j < bordArray[i].length; j++)

bordArray[i][j] = new Player();

{

char userLetter;

System.out.print("Sorry that is no good, choose a capital letter. Try again! ");

userLetter = Input.next().charAt(0);

given the cumulative distribution

F(x)=x

f(x)

. b) Find

X

Questions 204

1

<

ε

(x

,i>i

(x,y

, and

and the approximate relative percentage error

(x,y

, and

The main method must print in the interactions panel (as text mode) the following line as the first line of output

“written by xxxx”

An array of colors that will later be assigned to each form

A drawing panel of 400 and 400 pixels in size

". The second line will show the following: "SyncedForms - written by

xxx".

110.00

\\ \hline E &

45.00

\\ \hline D &

90.00

\\ \hline D &

250.00

\\ \hline B &

Apply formula here (Cell B18) } \\ \hline Average of D &

250.00

\\ \hline D &

50.00

\\ \hline C &

25.00

\\ \hline A &

23.00

\\ \hline A &

?

\\ \hline \end{tabular} Q.9.1. In table 1, what is the average of products B and D? (Apply the formula in Cell B18 and B19) ( 2 marks each) Q.9.2. In table 2, what is the average semester score? (Apply the formula in Cell E13 and E14) ( 2 marks each) Q.9.3. In table 3, what is the average of West zone? (Apply the formula in Cell A37) (2 marks) Q.9.4. In table 4, what is the average of unit sold above 250 and 100? (Apply the formula in Cell G36 and G37) (2 marks each)

Questions 209

2) Answer the following: Fields of Employee class: Id (int), name (String), dateOfJoinlng (LocalDate), gender (String), salary (float). There is a scene to populate a TableView with Employee rows using user input. The addNewEmployeeButtonOnClick() handler method will capture employee detalls from user and add a row to the TableView, using following fxids as given below: There is another handler method called saveTableViewToGenderSpecificBinaryFilesButtonOnClick(). Clicking this button will create/append-to two binary files with Employee instances from the TableView as follows: - MaleEmployees.bin (contain male employee instances only) - FemaleEmployees.bin (contain fernale employee instances only) Now: A. Write the initialize() method [10 marks] - to preload the combo box with some department names - to configure the TableView B. Write addNewEmployeeButtonOnClick() method [15 marks] C. Write saveTableViewToGenderSpecificBinaryFilesButtonOnClick() method [20 marks]

Coding:

regular expressions, that the password starts with a letter, includes at least a digit, a special character and its length is at least 7 characters.

Iarray.py

import abc

@:param instance an optional Array instance to deep copy data from.

Should only copy the smaller of size or len(instance) items

pass

""" Clone the array

@staticmethod

def clone(instance):

@:return the item at the index

@:raises IndexError if the index is out of bounds

""" Bracket operator for setting an item

Usage: array[index] = val

"""

@abc.abstractmethod

@:return the length of the Array

"""

Usage: array.resize(5)

@:param new_size the desired new size

pass

""" Equality operator ==

@abc.abstractmethod

def __eq__(self, other) -> bool:

"""

@abc.abstractmethod

Usage: del array[0]

@:param index the desired index to delete

pass

""" Contains operator (in)

@abc.abstractmethod

def __contains__(self, item) -> bool:

def __init__(self, size):

raise NotImplementedError()

def __setitem__(self, index, data):

raise NotImplementedError()

def __eq__(self, other) -> bool:

raise NotImplementedError()

def __contains__(self, item) -> bool:

raise NotImplementedError()

def setUp(self):

self._array = Array(10)

def test_index_operators(self):

raise NotImplementedError()

def test_eq(self):

raise NotImplementedError()

def test_contains(self):

raise NotImplementedError()

if __name__ == '__main__':

unittest.main()

You've just completed your computer science degree and have been asked by someone you know (referred to as X below), to create a web site for their small business. X wants to have the following for a corporate web site:

a place for persons from the public to see all items available for purchase

X as the owner needs to be able to create/modify/delete products on the web site

X as the owner needs to be able to see all users' purchase details on the web site (e.g., to fulfill their orders)

associations between the various actors and roles

if dependencies should be labelled then do so --otherwise don't label them

Questions 216

Problem 1: (20 marks) Blockchain is a type of ledger that facilitates the process of transactions that is duplicated and distributed in a business network. An asset can be tangible (a house, car,) or intangible (intellectual property, copyrights). Briefly, in not more than 80 to 100 words. How does Blockchain work?

1,1500

. For the class calendarType, include the following operations: a) Determine the first day of the month for which the calendar will be printed. Call this operation firstDayofmonth. b) Set the month. c) Set the year. d) Return the month. e) Return the year. f) Print the calendar for a particular month. g) Print the calendar for a particular year. h) Add the appropriate constructors to initialize the member variables. Finally, write a test program to exercise all functions in the classes you created and make sure you print the calendar for either a particular month or a particular year. The example on the page 8 prints the calendar month for September 2019 and the calendar year for 2018. MUST LOOK LIKE THIS Enter the date (MM DD YYYY): 06222022 June 22,2022 Days gone in the year: 173 Days left in the Year: 192 Enter number of days to be added: 3 After increment date: 6-25-2022 Create and Test "dayType" object initialized to "Wednesday": Wednesday Next Day: Thursday Set Day: Sunday Previous Day: Saturday Add 12 days to "dayType" object After Add days: Friday Create and Test "calendarType" object initialized to "September 2019": Enter calendar year to print. (YYYY): 2020 Print Calendar Year for 2020

19+/−5

Note:

A

A

A

C

6

10

25

30

46

9

3

10

4

jobs arrived: Total number of c jobs completed: Total number of D jobs arrived: Total number of D jobs completed: Total time CPU(s) were processing: time units Total time CPU(s) were idle:

time units Each test run creates a log file of actions (sample below from 2 CPU test). Run Time and Idle Time reset to 0 when a processor toggles from run to idle or idle to run: Time 1: Queue: Empty; CPU 1 Idle Time:1; CPU 2 Idle Time:1; Time 2: Queue: Empty; CPU 1 Idle Time:2; CPU 2 Idle Time:2; Time 3: Queue: Empty; CPU 1 Idle Time:3; CPU 2 Idle Time:3; Time 4: Queue: Empty; CPU 1 Idle Time:4; CPU 2 Idle Time:4; Time 5: Arrival: Overall Job:1, Job A:1, Processing Time 6; Time 5:- Begin Processing Job:1, Job

1:2

Time 11:- Begin Processing Job:3, Job B:1 in CPU 1 Time 11:- Queue: Empty; CPU 1 Run Time:0; CPU 2 Idle Time:0; Process completed jobs then arrivals if at the same time. The status statement showing queue and

Q.java

class Q

R r = new R;

int x = r.one();

R.java

class R

}

Clearly, the sequence diagram will start in Q.process(). Model Q.process() in the sequence diagram. Remember to show the Q and R objects with timelines at the top of the sequence diagram.

1. Design a Home Page which contains a navigation bar in the header. Navigation bar contains items for Home, About Us, Contact Us and Login. The navigation bar should show which menu item is currently active. Include at least one image in the Home Page with few lines about the business. Footer to use message "Copyright (C) 2022-2023", use Glyphicon for the copyright symbol. 2. Design a Login Page and apply the necessary validations. Login page should consist of the following: a. Username and password - which will enable the users of the system to login if they have a valid account. i. Admin user can login directly to the system by using "admin" as a username and "abc123" as a password. ii. Employee user should Sign Up first before the system allows them to login. Page 2 of 6 b. Sign Up- this option will allow employees to create a valid account first in case they don't have one. The page should contain a form which will allow the employee to save his/her details to the system database. The form should include username, email, phone number, password, and other employee details (provide at least 7 fields to collect employee details). The form should include different input form elements such as text boxes, drop down, check box and radio button. Provide message for successful registration. c. Forget Password - This option will allow all the users of the system (admin \& employees) to change the password. Provide message for successful update. 3. When the admin login to the system, the Admin Homepage should open. The page should contain options for the admin to View All Employees, Search an Employee, Change Password, and Logout. a. View All Employees page allows the admin to view all employee records in a table and sorted according to employee's name in descending order. It should display all employee details. The link to delete the record should be included in this page. There should be a link to go back to the Admin Homepage. i. Allow the admin to delete a record. Provide a message for confirmation and successful deleting of the record. There should be a link to go back to the View All Employees page. b. Search an Employee page allows the admin to search the database table for specific information (assign your own search key). There should be a link to go back to Admin Homepage. c. Change Password page allows the admin to change his/her password. Provide confirmation message for successful update. There should be a link to go back to admin homepage. 4. When the employee login to the system, the employee homepage should open. The page should contain options for the employee to Update Profile, Change Password, View Incentives Details and Logout. a. Update Profile page allows the employee to update his/her details except for the password. Provide a message for successful updating with the updated information. There should be a link to go back to employee homepage. b. Change Password page allows the employee to change his/her password. Provide confirmation message for successful update. There should be a link to go back to employee homepage. c. View Incentive Details page allows the employee to view a list of all his/her incentives with details (provide at least 5 fields of details for each incentives). The link to register should be included in this page. Provide confirmation message for successful registration. There should be a link to go back to employee homepage. 5. Design About Us page which should contain at least two paragraphs about the site. Add at least two images. There should be a link to go back to Home page. 6. Design Contact Us page which should contain the telephone number, email, Instagram, Facebook of the company, use Glyphicon for the social media icons; the page should include hyperlink to go back to Home page.

Questions 223

In developing the code, you are required to use at least 3 methods to solve the problem. The script should use command-line arguments for tasks 1 and 2 above. Please remember to include a help option that would make it easier for me to execute the code.

Questions 224

entity FSM is

port (CLK : in std_logic; --Clock, active high

);

end entity;

in_1,in_3,in_6,in_5, --represent the current sum of money after returning change

change_1, --should return change of 1$

process(CLK,RSTn)

begin

end if;

end process;

case current_s is

when idle => --state reset or idle

when put_money => --wait for money to be entered

if(CoinIn = "00")then

Soda <= '0';

CoinOut <= "00";

next_s <= soda_out;

elsif(CoinIn = "11")then --insert 5$

------------------------------------------------------

when in_1 =>

elsif(CoinIn = "01") then--inserted another 1$

Soda <= '0';

CoinOut <= "00";

next_s <= in_3;

end if;

------------------------------------------------------

------------------------------------------------------

when in_6 =>

when in_5 => -- input = 5 coin

Soda <= '0';

Soda <= '0';

CoinOut <= "01";

CoinOut <= "00";

next_s <= put_money;

NOTE :

1. PLEASE WRITE THE CODE IN C

Please use bubble sort to finish sort_section function, the ptr and qtr is a pointer that points to the start/end of the section.(ptr ≠ qtr, but ptr might be bigger than qtr)

Input

Your code will be judge using this program:

#include <stdio.h>

scanf("%d%d%d", &N, &a, &b);

int arr[ARR_MAX] = {0};

for (int i = 0; i < N; i++) {

printf("%d ", *(arr + i));

15

4 11

-98 -21 -58 -11 -55 55 118 141

-98 -58 -21 -55 -11 55 118 141

Example 2

Input

-78 74 -87 95 -86 120 102 143

-78 -87 74 -86 95 102 120 143

-87 -86 -78 74 95 102 120 143

104 119 -87 -86 -78 74 95 102 120 143 219

void sort_section(int *ptr, int *qtr);

// Driver program to test above functions

int arr[ARR_MAX] = {0};

for (int i = 0; i < N; i++)

for (int i = 0; i < N; i++)

{

void sort_section(int *ptr, int *qtr)

{

arr[N] = *(ptr + N);

N++;

for(i = 0; i < N - 1; i++)

{

l = ptr[j];

ptr[j] = ptr[j + 1];

{

printf("%d ", ptr[k]);

Questions 226

Consider the followina the flat database table: Convert this flat database table into relational database

If a node is red, then both its children are black.

For each node, all simple paths from the node to descendant leaves have the same number of black nodes.

hour to complete a portion of an assigned task then ABC pays 100 TL; for its 1 hour portion 500 TL; for

1.5

hours today, you can't realize it in two consecutive overtime working slots of 1 hour

+1.5

hours length task assigned to you and to compute how many days it takes to complete the assigned task. Figure 1. An example overtime payment values for portions in half-hour siots. For the above problem instance and an assigned task of length

N=2.5

. Another optimal solution is obtained by completing portion 2 first then portion 3 . i. Design a polynomial-time algorithm that solves the Remote Worker's Overtime Plan problem on paper by applying the steps of Dynamic Programming and submit it as your project report ( 30 pts) ii. Implement an iterative (not a recursive) algorithm based on your design in part(i)

(60pts)

(b) The dynamic set operation MIN-GAP returns the difference of the two closest numbers in a dynamic set Q of numbers. For example, if Q = {1, 5, 9, 15, 18, 22}, then MIN-GAP returns 18 − 15 = 3, since 15 and 18 are the two closest numbers in Q. How can you augment a red-black tree to support the operation MIN-GAP in constant time? Please explain the following.

(i) Normally, every node of a red-black tree includes the following fields: parent, left child, right child, key value, color. What are the additional field(s) augmented at each node of the red-black tree to support the operation MIN-GAP in constant time? For every additional field, provide a clear description, and a precise defini- tion.

(iii) Is it possible to maintain these additional fields so that the running times of dy- namic set operations, such as SEARCH and INSERT, on a red-black tree with n distinct keys are still O(lg(n))?

Questions 231

block with even parity checks is received as a) Which bit is an error? (redraw the corrected data matrix sent) b) Give an example of another received data where there are bit error(s) but the even parity checks can't detect them

Questions 233

the assignment of the new entry: Maths

=6

for i in range(len(vec1)-1): dist

+=

Questions 234

An aircraft will take off from the Ankara Esenboga Airport runway

500ft

.), d) Draw and indicate the general locations of the ILS components for runway 11 of Trabzon Airport. Write the information provided to the aircraft by the ILS components during the approach.

C

more than three times in a row. (Number 4 on a Roman numeral clock is usually written, incorrectly, as IIII.) Symbols V, L, and D cannot appear more than once consecutively. Do not subtract a number from one that is more than 10 times greater: ir I may only precede

L

and

D

and

M

LC because it is the same as

because it is the same as

V

f) Use these function names in your class: void setRoman(string); bool romanValid(); void romanToPositiveInteger(); void printPositiveInteger() const; void printRoman() const; romanType(); romantype(string); 1g) Subrri. your class header file (romanType.h) and implementation file (romanType. cpp). Below is an example of what your output must look like: output should match this exactly: Enter a roman number or

Q/q

to Quit: MDcccLxxxVi i The equivalent decimal number of the Roman numeral MDcccl

x×xVi

to Quit: Hello Invalid Roman Digit Enter a roman number or

Q/q

please help me improve my code with the given problem: Write a java program which determines whether an input string is a palindrome or not. Your program should take into account letters only and ignore nonalphabetic characters as well as consider letter case (uppercase or lowercase) immaterial in the determination. For example, the string "Madam, I'm Adam." will be considered a palindrome, even if its "reversed" form (which is ".madA m'l,madam") does not match exactly its original form. This is so since, if letter case and nonalphabetic characters are ignored, the string reduces to "MADAMIMADAM", which is the same read forwards and backwards.

My Code Below: Needed to improve starting from the example of the problem

// variable to store the original and reversed string

String original, reverse = "";

original = in.nextLine();

// getting the length of the string

reverse = reverse + original.charAt(i);

}

}

// otherwise

in.close();

}

Part-1 (5 marks) (Classes, Objects, Inheritance, Polymorphism, Overloading, Overriding) ___________________________________________________________________________ Create a C# console app with a base class and one or more derived classes to represent some real-world entity such as a bank with customer accounts, student with different registered courses etc. The base class will: a) Create a total of 3 member variables for the class by selecting the appropriate data types for each field. Each of these 3 variables needs a data type. b) Include at least two different constructor methods including the default constructor (no argument constructor). c) Create and override the toString() method to display the values of an object in a formatted manner. The derived class will: a) Create a total of 4 member variables for the class by selecting the appropriate data types for each field. Each of these 4 variables needs a data type. b) Include at least constructor methods including the default constructor (no argument constructor) that will create the base class objects. c) Create and override the toString() method to display the values of the base and derived class in a formatted manner. Implement using a C# console application the following: a) Instantiate „n‟ number of objects. b) Store the objects into an array. c) Utilize the toString() method to display the content of an object created from the array. Include the below in your project report: a) Base class, derived classes and test program b) Screenshots of output generated from the application. ________________________________________________ Part-2 (5 marks) (Graphical User Interfaces) ___________________________________________________________________________ Create a C# Windows form app that demonstrates various controls and components that you have learnt. You can also include User Controls in your project. Design form using the classes from Part-1. Create a form that consists of the following:  Form title: “Title of your project”.  Design your form by using different controls like TextBox, Label, Button, ListBox, DateTimePicker, Menus and Toolbars, etc. (Minimum five different user interface controls should be used.  Use event handlers to activate and implement the GUI components/controls. (Minimum three different events should be created) Include the below in your project report:  Screenshots of all output generated from the application.  Code for the program ___________________________________________________________________________ Part-3 (5 marks) (Introduction to LINQ) ___________________________________________________________________________ Using the concepts you have learned about collections introduce the concept of List to store the objects created from Part-2. Modify the form designed in Part-2 to include the following:  A control to display the objects in sorted order based on any one member field using the features of LINQ with arrays  A control to display the objects details obtained by filtering the List using LINQ statement. Include the below in your project report:  Screenshots of all output generated from the application.  Code for the program.

Questions 239

iii. Humans are very good at making errors. Identify different types of errors and give an example for each type of error when using the software. In our interface design, how can these errors be prevented?

(5 + 5 + 10 marks)

Questions 241

Subjects: Tools and Techniques for Data Science

M=(Q,Σ,Γ,δ,q)

such that:

(p,a,b,a,R]

[q,b,q,b,R]

[p,b,p,b,R]

[p,c,p,c,R]

[t,c,c,R]

[c,Z,c,Z,R]

[s,Z,c,Z,R]

(M

0

diverges. Note: In the answer to the two parts of this problem, you are requested to provide a total of 30 distinct individual strings. Every correctly listed string earns a certain amount of credit, but every incorrectly listed string loses the same amount of crodit. Empty space is neither correct nor incorrect. If your score on this entire problem is negative, it is automatically converted to zero. Advice: Do not guess. (a) Write 15 dlstinct strings that belong to

L

s

=(a∪b)

Questions 243

i. What input and output devices would you use for the following systems? For each, compare alternatives and if appropriate indicate why the conventional keyboard and mouse may be less suitable. a. Tourist Information System b. Air Traffic Control System c. Word Processing System (10+10+10 marks) ii. Describe the interaction framework in

r

represents the width: height ratio of the screen, - d represents the distance between the user's eyes and the centre of the screen surface, and -

r,d

and

±15

′′

,17

21

′′

, and

4:3∼1.33

and

y

They operate the same way – they just come from different libraries (scikit-learn and NLTK).

Lemmatisation cuts off part of the word while stemming considers the morphological analysis of the words.

. Une méthode changeTaux(valeur) devra permettre de modifier ce taux à volonté, - Une méthode capitalisation (nombreMois) devra : afficher le nombre de mois et le taux d'intérêt pris en compte; calculer le solde atteint en capitalisant les intérêts composés, pour le taux et le nombre de mois qui auront été choisis. Exemples

d

≫>

ol.affiche () Le solde du compte bancaire de Duvivier est de 950 dollars.

984.769981274

dollars.

cl.capitalisation (12) Capitalisation sur 12 mois au taux mensuel de

0.5%

Question 3 i. Consider the activity of withdrawing cash, with a receipt, from an ATM machine. Carry out a hierarchical task analysis (HTA) of this activity. You may present your answer either as text or in the form of a HTA diagram. (30 marks) ii. The heart of user centred design is getting frequent feedback from users. To do so, the evaluation task should be carried out during a Software Development Life Cycle (SDLC), a process followed for a software project. Describe what items should be evaluated at what stage. (25 marks) iii. Members of clerical staff at an insurance company are required to enter a variety of dates into a computer system on a regular basis. In the design of the user interface, two methods for the input of the dates are proposed: - Fill-in fields using templates for the date format (e.g. dd/mm/yyyy) - Selection from combo boxes (for day, month, year). Figure 2: Date Input Method One riyule s. wale mput ivieutiun inv The management wants to have good productivity. In other words, the dates must be correctly entered as quickly as possible. Therefore, there is a need for the interface designers to conduct some experimental study regarding the use of the two date input methods. The users will be provided digital prototyping for the two date input methods (similar to Figures 1 and 3). Each participant's task is to use one of these prototypes to enter the date and record the appropriate metrics. Give your advice on the following points for the experimental study: a) What is the null hypothesis, and the alternative hypothesis? b) The independent and dependent variables. c) The participants to be selected for the experiment (in terms of the number and characteristics) d) The experimental method you would choose accordingly e) Tasks of the experiment f) Statistical analysis to be conducted.

Questions 248

to unlock. b. (20 pts) Design a Finite State Machine to show the correct operation of the binary combination lock.

Questions 250

the normal order precedence of arithmetic operators

the relational operators have lower precedence than arithemetic operator

3-4/2+67 < 15 AND 5< 2 OR 8>9

b. Evaluate the above expression assuming the following rules:

Evaluate the expression from left to righ

Questions 252

pts) Write down the Verilog HDL model of the binary combination lock.

Questions 253

cout<<<< "List Element is " << list[index]<<<< endl;

a. Write down what the above code will print out if the variable value was equal to 2 in case that the language supports short circuit condition for

j

th character in Pass1, where (i+j)

N

users. Output Specification: Your task is to return the total number of distinct passwords present. Example 1: input1: 2 input2: \{abcd,cdab\} Output: 1 Explanation : "cdab" can be obtained from "abcd" by swapping 0th and 1st elements with 2nd and 3rd elements, respectively. Since, there is only 1 distinct password. 1 is returned as the output. Example 2: input1: 2 input2: \{abcd,bcad

When writing your answer, please use full name and abbreviation for all terms.

Questions 256

Questions 258

3. Write two ways to solve the IPv4 address depletion problem.

Questions 260

Briefly explain what Software Defined Networking (SDN) is and write one advantage of SDN.

Questions 262

7. Answer the following questions.

1. Use the decision tree learning algorithm in the text to create a decision tree for the below data set. Assume all attributes are binary (and that Example is not an attribute). Use the entire set of examples when generating the tree. Be sure to show the calculations used when choosing an attribute. In the finished tree, show the set of examples corresponding to each node as well as its entropy. 3. Suppose for a binary classification problem that you have a data set of 50 examples, evenly split between positive and negative examples. If leave-one-out cross-validation is used, how will a simple majority classifier perform? Such a classifier outputs the class that is in the majority in the training set, regardless of the input. Please explain. 4. Suppose we want to develop a linear model

w

x

x

1

and

y

is the target. (a) If the weights are initialized to 0, what will the sum of the squared error be? Show your work. (See Sec 18.6.1). (b) Using learning rate

, what will the new values for

w

1

(2) Write down the advantages of slotted ALOHA over pure ALOHA among Random access MAC protocols.

(3) Write two things: Taking-Turns MAC protocol.

Questions 266

Q1)

Red(R)

,

3×3

structure, where 8-neighbors of the center pixel is included, remove the noise in the below image where R, G, B color channel values are given separately. Clearly show intermediary steps for this operation. b) Later on, (i.e. for the resulting image that you achieve in (a)) apply Clipped Mean technique with the threshold

Z

is computed with the last two digits of your student ID number

what is the aim and objective and methodology of Encrypting Data Transparently with Transparent Data Encryption?

Questions 269

When you create a reply, all termination with null name and pharmacies.

Questions 271

Problem 2: Write a program that asks the user for an integer

n

A word is a palindrome if it can be spelled the same forwards and backwards. The words "radar" and "racecar" are examples of palindromes. A stack be used to determine if a word is a palindrome.

Discuss how this can be done.

//

use linkedlist //searching alogorithins and sorting algorithims

koch ibner fahent Pvach honerid p ame pa ient N6 pk Shithme Ndme Sala9 addr ess vegi stev paien t manage sersc)D Phene rea ojntmi appointm entg Consui ) reatment Surgeov pk Surg eonid pk Repov Date Name Lepotidp Surgeo Specal'Saion Phane_ kyPe Chece SSes PicseuPek) ecov& enevafe) Checkc), what is this in the final answer could you please explain

Questions 278

Questions 280

Case Study LH Medical Company (LHM) LHM is a London based privately owned hospital which provides healthcare to its patients. The hospital uses in-house software to manage and service its patients which they refer to as clients. It is an expanding venture and needs to accommodate for processing its information globally. The practice management system is web enabled and multi-platform for connectivity via web services, in addition it has connectivity to existing legacy systems. An enterprise document management system ensures patient documents are replicated globally and available per demand. In addition to medical treatments, medicine and drugs, consultation and vaccinations are offered to its patients (with a variable additional fee) the company offers medical instruments to other companies either to purchase or to lease. LHM records the details of its clients with possibly their full medical history in their computer system. When a new patient requests an appointment (walk-in or on-line) a treatment course begins and a practitioner is allocated to the patient. A full history and previous medical records are printed showing different categories of Treatments during different time intervals. Analyses are drawn in terms of any possible allergies and previous histories. Treatments may involve many surgeons and consultants depending on its complexity. The contact practitioner is responsible for estimating the costs of treatments that is agreed by the client at the start of the treatment. The duration of the treatment may be set at any time duration and may also be changed during the treatment depending on the complexity of possible operations. The final cost and completion date are recorded at the end of the treatment. During a treatment process, notifications may be sent to patients and other practitioners. Repeat prescriptions may automatically be produced by the system if appropriate and are available for collection at any surgery by the patient. At any time, a practitioner may suspend or cancel the prescriptions. The cost for a treatment is paid for by the client or an insurance policy provided by a number of insurers. Insurance policies may have additional surcharges and costing depending on treatment types and medicines. Long term treatment courses may be edited or cancelled by practitioners or clients. To re-start an existing treatment an additional fee is applied. LHM may receive requests for specialise treatments from other hospitals or they may refer clients to other medical centres. Each treatment course or service may include one or more of the following items: • Operations and vaccinations • Consultations and check-up • Medicine and different types of tablets • Clinical reports and attached documents and history • Prescriptions and repeat Prescriptions A treatment course comprising services from other hospitals carry additional changes set by the medical service providers. A full list of Treatment courses may be requested by the site manager at any time.

Page 2 of 4 5. Create another Razor page named 'Purchase' under the 'BurgerTest' folder. This page should process the following kind of queries: https://localhost:xxx/BurgerTest/Purchase?BurgerType=3&BurgerCount=4 This processing requires you to modify the OnGet() function in the 'Purchase.cshtml.cs' file as follows: a. Add two function parameters: int BurgerType and int BurgerCount b. In the function body, calculate the total price for purchasing burgers of BurgerType with the quantity of BurgerCount. The pricing should be based on the Table 1 above. c. In the function body, pass the following values to the content file 'Purchase.cshtml' by the ViewData dictionary: i. The burger name corresponding to the BurgerType based on Table 1. ii. The total price to pay. Hint: the easiest way to implement this function is to use the “switch” statement in C#. See https://www.w3schools.com/cs/cs_switch.asp.

Questions 283

Find and report about the tools of finding people information

Questions 285

Case Study LH Medical Company (LHM) LHM is a London based privately owned hospital which provides healthcare to its patients. The hospital uses in-house software to manage and service its patients which they refer to as clients. It is an expanding venture and needs to accommodate for processing its information globally. The practice management system is web enabled and multi-platform for connectivity via web services, in addition it has connectivity to existing legacy systems. An enterprise document management system ensures patient documents are replicated globally and available per demand. In addition to medical treatments, medicine and drugs, consultation and vaccinations are offered to its patients (with a variable additional fee) the company offers medical instruments to other companies either to purchase or to lease. LHM records the details of its clients with possibly their full medical history in their computer system. When a new patient requests an appointment (walk-in or on-line) a treatment course begins and a practitioner is allocated to the patient. A full history and previous medical records are printed showing different categories of Treatments during different time intervals. Analyses are drawn in terms of any possible allergies and previous histories. Treatments may involve many surgeons and consultants depending on its complexity. The contact practitioner is responsible for estimating the costs of treatments that is agreed by the client at the start of the treatment. The duration of the treatment may be set at any time duration and may also be changed during the treatment depending on the complexity of possible operations. The final cost and completion date are recorded at the end of the treatment. During a treatment process, notifications may be sent to patients and other practitioners. Repeat prescriptions may automatically be produced by the system if appropriate and are available for collection at any surgery by the patient. At any time, a practitioner may suspend or cancel the prescriptions. The cost for a treatment is paid for by the client or an insurance policy provided by a number of insurers. Insurance policies may have additional surcharges and costing depending on treatment types and medicines. Long term treatment courses may be edited or cancelled by practitioners or clients. To re-start an existing treatment an additional fee is applied. LHM may receive requests for specialise treatments from other hospitals or they may refer clients to other medical centres. Each treatment course or service may include one or more of the following items: • Operations and vaccinations • Consultations and check-up • Medicine and different types of tablets • Clinical reports and attached documents and history • Prescriptions and repeat Prescriptions A treatment course comprising services from other hospitals carry additional changes set by the medical service providers. A full list of Treatment courses may be requested by the site manager at any time.

Task 4 Component Models Produce ONE Component with associated interface methods to represent the class diagram in Task 2. As part of your solution, illustrate various possible component composition and discuss the significance of your design. [10 marks]

x

x+a

0

for

)

1x+a

<−c(4,3,2,1)

n_Minus_One <- length(a)

(mult,−1)

result Hint: One can multiply lists element by element simply by using a

C

and it's not necessary to get same vofit brovided using values are different).

(0−90

Write a Hangman Game c# code

There should be four criteria: Country name, Football Player Name, Flower Name and Fruits Name

Questions 293

Find the determinant of the 50000x50000 matrix (the numbers in the matrix will be randomly generated by the program) using the swap method and the synchronization objects?

Hint :

1. Make Augmented RE

Write a simplified machine language program that has register

$sθ

When is machine learning most useful?

Select an answer:

Questions 298

Q6. [10 pts] For the graph

G

above is isomorphic to the graph

−∞

sin

2

a

Consider the function defined below: Which of the following calls will notigenerate an error? average_numbers

1,n4=4,2,n3=3)

Questions 301

Python check good square Expected output:

It is not a good square because it contains duplicates, namely: 1

>>> f(0, 3, 5)

It is not a good square because it contains duplicates, namely: 2 3

>>> f(0, 6, 50)

6 39 16 34 45 38

9 19 6 46 4 43

24 48

26 2

>>> f(0, 3, 100)

Here is the square:

Ordering the elements from left to right column, from top to bottom, yields:

5 49 62

3155 3445 331 2121 4188 3980

3317 2484 3904 2933 4779 1789

It is a good square.

Ordering the elements from left to right column, from top to bottom, yields:

824 2052 2704 3556 4134 4779

1140 2121 2898 3626 4188 4930

def f(for_seed, n, upper_bound):

seed(for_seed)

display(square, len(str(upper_bound)))

# Insert your code here

print('It is a good square.')

print('Ordering the elements from left to right column, from top to bottom, yields:')

2- Normalize (3NF) and create a physical design for a simple database

3- Create database objects including Tables and Integrity constraints.

Furthermore, the communication and sharing of information between offices, even in the same city, is poor. The Director of the school feels that too many mistakes are being made and that the success of the school will be short-lived if he does not do something to remedy the situation. He knows that a database could help in part to solve the problem and has approached you and your team to help in creating a database system to support the running of the DrivingSchool. The Director has provided the following brief description of how the DrivingSchool operates.

Data Requirements:

(a) The names and telephone numbers of the Managers of each office.

(b) The full address of all offices in Jerusalem.

(h) The names of clients who have sat the driving test more than three times and have still not passed.

(i) The average number of miles driven during a one-hour lesson,

Primary Key staffNo

Alternate key ID

Include screenshots for three tables.

Part 3 – Query the Database

any comparison of Encrypting Data Transparently with Transparent Data Encryption?

Questions 304

dimensions 7 x 1 within range [5 25] and then solve this system using gauss-

elimination method using partial pivoting.

X4 =

X5 =

Questions 306

This question is about race conditions and mutual exclusion. Which of the following statements are true? Select one or more: a. Mutual exclusion should be used even when only one process accesses a particular resource. b. Mutual exclusion should not be enforced in non-critical regions. c. A program can only have one critical region. d. Race conditions can be avoided by using a mutual exclusion mechanism. e. Critical regions consist of code that should never be executed.

ex:

0 should pass

01010101 should pass

0000000010000 should pass

==0)

fork(); pid

(0);

Questions 309

Select all the correct statements about memory management: Select one or more: b. All segments of a process are part of the same address space c. In a multi-level page table, page frame numbers are contained in the top level table d. The content of a page in main memory may be different from that of its version in the backing store e. In operating systems with static relocation, virtual-to-physical address translation is performed when instructions referencing memory are executed

Questions 311

heading below the burger image. Hint: You need to embed C\# code into the content file with Razor syntax. Again a 'switch' statement gives you the most efficient implementation. Inside this 'switch' statement, you decide the image file name for the burger and store it into a string variable, say, 'imagefile'. Then, in the tag, you can do . Also, look at our sample project for Lecture 2. An exemplar testing result for step 6 Enter the URL https://localhost:xxx/BurgerTest/Purchase?BurgerType

=3&

Name: Assume the pipelined data path and the forwarding and hazard detection unit that you have implemented in the lab. Answer the following questions regarding the code. sequence given below: 1. Draw the pipeline execution diagram for the above code sequence where all data fnnwarris are marked with arrows and stalls are marked with bubbles.

Questions 313

, and the following table gives details for the process's pages currently in memory: Select all the correct statements about the execution of the working set algorithm on these pages. Assume that the algorithm examines pages in the order they are listed in the table (from 1 to 5). Select one or more: a. The time of last use of page 2 is set to 20 b. Page 4 is selected to be removed c. Page 5 is selected to be removed d. Page 1 is not in the working set

Previous question

⋆⋆⋆

Reservation

23/10/202209:00−13:00

[3] Cancel Reservation Your Choice: R1.7 Modify Reservation The system should prompt the user for a reservation number. If a valid reservation number is entered, the system should display the details of the reservation, and options on which details are to be modified.

X

to cancel: The system should continue to display the updated details such that the user can modify more than one details. R2 [2] Show Reservation Record The system should display the next 7-day conference room reservation records in a cale format. Return to Main Menu The system should return to the Main Menu if the user enters

In Practical Set 1, you will create a simple website by ASP.NET Core Razor pages for a fictitious burger shop named "Gourmet Burger". This burger shop sells four types of burgers, which are detailed in the following table: Table 1: Burger Details Steps for completing this practical set 1. Create an ASP.NET Core Razor Pages project named "BurgerYourSID" with Visual Studio. For example, if your SID is 12345678 , then the project should be named "Burger12345678". Since the project name appears everywhere in the source code generated by Visual Studio, this naming will help prevent source code sharing among students. 2. In 'Solution Explorer', create a folder named "BurgerTest" under the "Pages" folder of your project. 3. Create a Razor page named "Index" under the "BurgerTest" folder. Modify the automatically-generated 'Index.cshtml' file to display the Table 1 above in an HTML table. That is, when entering the following URL https://localhost:xxx/BurgerTest into the browser after running this project, the Table 1 above should be displayed in the browser. No styling or any styling to the table will be fine, as long as the table looks roughly the same as the one above. Hint: review how to display a table by HTML tags. 4. In 'Solution Explorer', create a folder named 'images' under the 'wwwroot' folder of your project. Then, create an image file for each of the four burger types and store these four files under the 'images' folder. You can download images from Internet and then modify them. When searching images on the Internet, you should use royalty-free image websites such as Pixabay I and Unsplash, to avoid copyright issues. The four images should all: 7. Modify the "Pages/Index.cshtml" to implement the following: a. Add a carousel that uses the four burger images created in Step 4. b. The images should be rotated every

1.5

. c. The first combined column should contain a welcome message to this Gourmet Burger shop; the second combined column should contain the following links arranged vertically in a bullet list. - Home: link to the Index page under 'Pages' folder. - Burger Index: link to the Index page under the 'Pages/Burgers' folder. - Privacy: link to the Privacy page under the 'Pages' folder. 14. Run your project, and then use the website from this project (in particular, the Create page) to add the data in Table 1 into the database.

Questions 318

Question Three

[25 marks]

a) Write down a java code to draw this function

b) Update the code in a) to draw the same shape but with wide noise around every drawn point.

I

that takes pixel intensity values from

3

1

6

3

7

;W=

2

10

4

I

. (b) Sketch the histogram of

J

. Show all your steps to receive marks. Assume zero-padding is used. (d) Verify your answer in (c) by Octave.

A

and plot the histogram. (c) Denoise the RGB image and have it saved as hw2_clean.jpg, i.e. recover the original image from hw2_noisy.png. (d) Apply edge detection on hw2_clean.jpg. Select an appropriate method and a suitable threshold.

Scholarly and/or professional material does not include:

Wikis, Blogs, Social media content

Questions 323

Motor Inheritance Hierarchy Create a base class called Motor which includes the basic attributes and member functions related to any vehicle. The private data members of this class include the following: - String variable which contains the brand name. - Integer variable which is the ID of the motor. - Integer variable which is the maximum speed of the motor. For this class you should provide the following public member functions: - Provide a constructor function that enables an object of this class to be initialized when it is declared. The constructor should contain default values in case no initializers are provided. - Print 0 : prints the values of all attributes of motor class. - Set and get functions for all data members. Write another two classes which are derived from class Motor: class Car and class Truck. Class Car includes the following additional private data members: - String variable contains the color of a car object. - Integer variable which is the price of the car. - Integer variable that contains the year model of the car. For this class you should provide the following public member functions: - Provide a constructor function that enables an object of this class to be initialized when it is declared. The constructor should contain default values in case no initializers are provided. - Override print(0 function in the appropriate format. - Function Compute that returns the price loss of the car, where each year lose

Questions 324

Find a subgroup of point group(4mm) in python(numpy library)

Questions 326

In order to calculate the food bill, your program should incorporate the following points. - Breakfast: Rs. 50 per breakfast - Lunch: Rs. 100 per lunch - Dinner: Rs. 70 per dinner. - Extra tea/coffee rate: Rs. 20 - Special ordered food rates Pizza per person: Rs. 300 Any Chinese food item: Rs. 200 Sandwiches/ burgers: Rs. 300 - Your program should ask the user for number of meals in 3 batches, i.e. it should ask number of meals for first ten days and calculate the bill, then for next 10 days and so on. Finally it should output as follows: Bill for first 10 days No. of breakfast:

2. Introduction to team software development

3. Opportunity to improve and use ones Java software skills in the improvement of an established open source project. Or, opportunity to start a brand new open source project.

3. Describe how the project can be used to further God’s kingdom and select an organization that you believe would benefit from its use and how. (2 pages minimum - 40)

4. Select a meaningful feature or issue to address. Make the changes and issue a pull-request. You must document and submit the issue, the submission, and the status of the pull-request. (2 pages minimum - 50)

and a bottom padding value of

10px

. - An : nth-child () pseudo-class must be applied to shade even table rows (see "Design Resources"). - A matching alignment for all numerical columns should be specified internally using a 'class' selector. - All "Total Reviews" and "Overall Score" values must be presented as shown. - Each "Overall Score" background colour should be specified internally using a 'class' selector. - The text shown beneath the table must be displayed within an

h3

i) Consider

G

coloured red and another vertex

v

• Project Description A restaurant has information about its menu and its prices stored in a Several files o Breakfast Menu : “BreakfastM.txt”. o Lunch Menu : “LunchM.txt” o Dinner Menu: “DinnerM.txt” o Kids Menu: “KidsM.txt” o Drinks menu: “Drinks.txt” In each file there are lines where each line containes information on the meal The provided meal informations in that line are: o Meal ID o Meal Name o Meal Ingredients o Price o Availability Each of those information is seperated with a comma, and the ingredients are seperated with a semi-colon. There is a order text file “Order.txt”that containes o Meal IDs o Meal Names. o Order amounts. Of each meal o Ingredients special request. o Price of each meal o Total price. • Project Requirements: o You program should should be a menu-driven one where the user will be asked to choose certain option and the program should continue to show the menu again as long as the user does not choose to exit. Sample Output: Restaurant: ----------------------------------------- 1. Dine-in Order 2. Exit ----------------------------------------- What is your choice: • Further details on the system: 1. function to show the menus for Dine in: If the user chooses that option he should be asked which Menu he wants to view and it should call the functions for the other Menus (function 4) 2. function to edit the meal ordered. This function takes a meal ID and menu option, ,When the user chooses a meal from the menu he should be shown a list of ingredient and the user should pick one of those options for each ingredient.  None  Regular  Extra (should add a 1% of the meal price)  A list should be returned where the options should be in the same order as the ingredient list 3. Function to calculate the price of a meal. This function takes the original price of a meal and the the list of ingredient adjustment and edits the price accordingly 4. Function to print the chosen menu This function takes the number of the option the user chose and upon that open the menu and ID List,Meal name list, nested list of ingredients, list of prices, Meal Availability(can the meal be ordered or not) list I. Breakfast menu II. Lunch Menu III. Dinner Menu IV. Kids Menu V. Drinks Menu Once one of them is chosen 4 lists should be populated with the file information, After that the user needs to choose a meal and then the function to add a meal should be called and once (note if the user doesn’t want a meal from this menu or if the meal he chose is unavailable he should be offered the option to go back to previous options). 5. Function to add meal to order This function takes a meal ID and that ID should be added to the order list, and ingredients option list should be populated as a list of lists where each of the list contains the ingredient option for each meal 6. Function to print the order This function prints the order to the “order.txt” file • Deliverables: Each team should submit a: o Pseudo code and flowcharts on how they are going to approach each function in the project. o File that contain the full python code o A report that contains:  Description on how the team members approched this solution.  Each team member’s contribution.  Descriptions of any extra functions they created.  Screenshots of the running code.

Python code

System.out.println("In int"

+x);

; Demo obj

=

I need to correct the distortion in this picture with MATLAB code only WITHOUT using undistortImage, UNDISTORTIMAGE of MATLAB!!!

for example from first image we get second one as a result. i send required image bottom of task​​​​​​​

Following is a list of things to keep in mind, before you submit your code, to ensure that your code focuses on attributes, we are looking for -

● Is the behaviour of an object distinguished from its state and is the state encapsulated?

● Have you looked at basic refactoring to improve the design of your code? (Here are some guidelines for the same.: https://refactoring.com/catalog/)

● Finally, and foremost, are the principles applied in a pragmatic way. Simplicity is the strongest of the traits of a piece of code. However, easily written code may not

● Account balance cannot exceed $100,000

● Account balance cannot be less than $0

● No more than 3 deposits are allowed in a day

● No more than 3 withdrawals are allowed in a day

command and return the output. Below are the commands that need to be supported along with

description, input parameters and the expected output for each command.

deposit amount. Returns the balance post deposit.

● Withdraw - Takes 2 parameters as input. First is the account number and the second is

failure.

○ All the deposit and withdrawal rules are applicable for transfer operation as well.

● Input: Create “Diana Prince”

Output: 1002

Output: 1500

● Input: Deposit 1001 100

Output: 11500

● Input: Deposit 1001 10000

Withdrawal

● Input: Withdraw 1001 500

Output: 10500

● Input: Withdraw 1001 1900

Output: Only 3 withdrawals are allowed in a day

Transfer

● Input: Transfer 1002 1004 30000

Output: Maximum withdrawal amount is 30000 for account 1002

_TRANSACTION_FEE

=3.5

i need code for GUI about A hotel that includes a page of info/personal details another page about check-inn and check out and last pick rooms ( two options are enough)

java GUI or HTTP or javascript page

Goals

Try alternative interpreter implementation supporting recursion without using the 'rec' type.

{count 8}} ;; Output: (numV 8)

{with {fac {fun {n}

{with {fib {fun {n}

{if {or {= n 0} {= n 1}}

----------------------------

(define-type DefrdSub

[aRecSub (name symbol?)

(value-box (box/c RCFAE-Value?))

Questions 338

Write a 5 page report in Arial font size 10 on the following Topic Penetration Test Methodologies An originality check will be performed. The report should properly cover at least 10 solid references.

x

in the array. Elements for which no greater element exist, consider the next greater element as

4→2

5→2

Output:

13→7

- The deadline for submission is 1 December 2022 at 14:00. - Only word-typed submission will be considered. - Only online submissions (uploads) will be graded. - The similarity of more than

20%

lines space, 2-3 numbered pages (excl. tables/figures, which needs to be in the end in an appendix). Topic Discuss the global macroeconomic impacts of COVID-19. (Helpful references: IMF, World Bank, OECD)

Questions 341

Chapter 08 Debug: Number Checker Create an application that checks whether an integer is an odd or even number. Console Welcome to the Odd/Even Checker! Enter an integer: ten Error! Invalid integer. Try again. Enter an integer:

10.3

:

y

[SQL BUSINESS VOCABULARY/Speech Questions]

⚠️=== Directions ===⚠️

=== ✨New Questions✨ ===

- Write in English using SQL Business Rules / Vocabulary

a.line1,

a.city,

JOIN addresses a ON c.shipping_address_id = a.address_id

WHERE

product_name,

SUM(oi.quantity)

p.product;

- Write the relational algebra expressions that will implement following SQL statement.

ON ol.product_id = p.product_id

[

I = im2double(I); % Simulate motion blur

LEN = 21; THETA = 11;

subplot(1,2,2);imshow(wnr2);title('restore image')

Questions 346

and label it properly 3. Draw a use case diagram for the purchase of medicine from the pharmacy 4. Take an example to describe the synchronous, asynchronous, and non-instantaneous messages 5. Discuss why/how object-oriented application frameworks can achieve software reuse. 6. What distinguishes an object-oriented application framework from a library? 7. What types of frameworks can be distinguished and what are the main differences between each of these types? 8. Explain and illustrate the Template Method design pattern and discuss its key importance to implement object-oriented application frameworks.

Questions 347

implementation to solve it using a stack. Write firstly the solution for 3 poles then generalize your solution to

n

4=4

BW1 = edge(I,'prewitt');

BW2 = edge(I,'zerocross');

subplot(2,2,4);imshow(BW3);title(' canny edge map ')

Questions 350

of the edges are displayed close to the edges. Select the correct statement: 1. There is a unique minimum spanning tree of

G

is changed to 8 , the minimum spanning trees of

G

and the weight

w

is set to

d

is set to

g

terminates all the disjoint sets have the same parent 4. None of these answers is correct.

Questions 351

se3 = strel('disk',3);

erodedBW1 = imerode(I,se3);

se2 = strel('ball',5,5);

I2 = imdilate(a,se2);

Questions 352

i want to connect 2 drones into single wifi connection. I couldn't figure out which software to use so i couldn't manage to connect them. can you help me with that problem, thanks :)

Activity – 1: 1. Read the csv file with data about the blood pressure:

Click this link or copy and past to browser.

1) Which course titles were given by at least two different instructors during the past?

2) Whichdepartmentshaveatleasttwoinstructorsandatleasttenstudents?

You should also present the output of each query in the lab report. Good luck!

Questions 356

2. Render multiple canyons - Create a global variable called canyons and initialise it to an array - Fill the array with lots of canyon objects. You can copy and paste from your original canyon object but be sure to alter the x_pos and width properties so that the canyons appear in different places in your game world. - Wrap your canyon drawing code with a for loop which traverses canyons using its length property - Replace references to canyon with canyons [i] (assuming that you used i as the variable in your for loop). - You should now see multiple canyons appearing in your game world

Questions 358

Code (e.g. Python as Jupyter Notebook, ...)

A- Finding Roots of Nonlinear Equations

Describe different integration methods, including the Monte Carlo Integration technique and show some examples

-D- Numerical Integration and Finding Roots of Nonlinear Equations (combination of B and C)

Implementing the SIR model in Python

-G- Ordinary Differential Equations

Finding Roots and Numerical Integration in the context of black body radiation finding roots to derive Wien's displacement law.

-J- Explore NumPy

V

Otherwise

(2)

: Let

(i,j)

entry is

\

to solve

b

ˉ

T

for

m=32

and 64. Write down your conclusions. Hint: For each coefficient matrix, it is helpful to evaluate the condition number to predict to which extent the matrix is ill/well-conditioned. The command vpa

d

significant digits. Problem (2): Let

(i,j)

entry is

\

to solve

b

ˉ

T

for

m=32

and 64. Write down your conclusions. Hint: For each coefficient matrix, it is helpful to evaluate the condition number to predict to which extent the matrix is ill/well-conditioned. The command

d

significant digits.

⟨h4⟩

heading. b. Display the image corresponding to that burger name underneath the burger name. c. Display the total price to pay in an

=4

, and the following should be roughly displayed: You purchased Angus Beef 7. Modify the "Pages/Index.cshtml" to implement the following: a. Add a carousel that uses the four burger images created in Step 4. b. The images should be rotated every

Questions 363

In Elgamal cryptosystem, given the prime q=13. choose a=first primitive root of p and k=10, calculate s1.

unsigned int i;

for (i=0;i<10;i++)

for

(i=0;i<10;i++)

" on the FPGA. Write an alternate version of this piece of C-code using user-defined data-types in Vivado- HLS so that when implemented, it uses less area than "

X

, answer the following? a) How many address lines are needed? b) How many data lines are needed? c) How many control lines are needed? d) What would be the size of MDR Register? e) What would be the size of MAR Register? Question 2: Given that the main memory access time is

1200 ns

please use (C language)

in question 6 My name is : Ghassan Churbaji please use this name on the answer

Weight

Questions 368

within the time domain

t=[

]

.

(t)+kx(t)=0

m:

: relative displacement k: stiffness

g(t)

(0)=0

(0)=0

versus time for cases of

x

max

x

max

x

for the questior

Question 3: In a computer with cache hit rate of

95%

: a) Find the miss ratio b) Find the average access time c) Find the improvement in performance where time to access main memory is 1000 (nanoseconds) and time to access cache is 100 (nanoseconds) Question 4: A cache memory needs an access time of

30 ns

)?

Questions 371

frequency CPU. The instruction cycle of the CPU has 4 steps and each step is executed in one CPU clock period. a) Compute the clock period of the CPU b) Compute the time needed to execute one instruction. c) Compute the time needed to execute the program.

Questions 373

eight

2. If you wish to work in a two-person group, both of the group members should send me (NOT to the course assistants!) an e-mail (hurevren.kilic@atilim.edu.tr) indicating the name of his/her agreed group member until 20.11.2022 (Sunday)

Hr:23:59

of your overall Homework \#2 grade, respectively. Submissions without joining face-to-face code review \& demonstration gets overall 0 (zero) grade from Homework \#2, directly. 5. Time table and place for the code review \& demos are planned to be announced later through the course Moodle site. For the groups, both group members should appear in the code review \& demo simultaneously while being ready with their submitted source code on their PCs. 6. Your implementation language could either be C, C++ or Python (No other languagel) Remote Worker's Overtime Plan: (100 pts) Remote working is becoming more attractive day by day. ABC company that you work for makes remote working payment to its employees for each portion the task in varying-half -hour slots basis. For example, if an employee works for

0.5

; for its 1 hour portion

500TL

etc. (see Figure 1 below). Notice that the payment amount is a strictly increasing function of work-hours. Assume that your employer assigns you a task that requires total

N

hours on the same day but instead, you can do it today either in one single

2.5

an optimal solution is to complete

1.5

Enter the payment value (in TL) for task portion ID 1 having length

0.5

hour(s): 1000 A SAMPLE OUTPUT: On Day 1 do task portion with ID 3 On Day 2 do task portion with ID 2 The most profitable completion of the assigned task takes

2

2.

x−y=1

Question 2 [1 pt]: Complete the truth table in Figure 1. Figure 1

Questions 377

{

public static void main(String args[]) throws Exception

final String SENTINEL = "done";

double hoursWorked = 0;

boolean done = false;

// Print two blank lines.

// Print two blank lines.

System.out.println();

done = true;

else // If not done, user enters hours worked

}

while(done == false) // While not done

System.out.println(DAY_FOOTER + " " + hoursTotal);

hoursTotal = 0;

hoursTotal += hoursWorked;

// Read in the next record

}

else

}

} // End of while

Questions 378

Compare and contrast data lakes and data warehouses. How does Azure allow you to control and monitor these types of storage? Does the company you work for currently use either? If not, do you think your company could benefit from employing them with Azure?

4. With a help of R code, explain how multiple views can be given to a shiny application?

5. What is meant by generic function in R? Explain with an example, how can you determine the class of a function?

Find the errors in the code, explain why its wrong, and apply a fix. Explain why the fix is better.

Questions 381

None) Result: "LList

→∣6∣:−>∣4∣:

: None; tail

−⟩∣4∣

None" 3. Call: remove_last(LList

→∣6∣:

; tail

−>

Write your program in C++. Write a function that accepts a pointer to a c-string or a function to a character array as its argument and returns the number of words contained in the string.

For example, if the string argument is "It is best to plan my school work every Monday morning", the function should return the number 11

Should avoid reading spaces before/after and in between words.

I can just enter spaces or nothing, and the result should be zero.

30%,20%

and

15ft

2

2

of solar cells needed to supply the city Number of solar panels needed to supply the city Cost of panels to supply the city Note: It is more likely that you would give this data to Marketing in an Excel file. There is a way to export a MATLAB array to Excel, but you do not need to do this. For each city you need to have calculations for each level of efficiency. See Table 2 for an example of part of the array. Name your file

Questions 385

1) What do you mean by creating a new IT Infrastructure in an organization?

6) Explain the Computer Architecture in-detail with a diagram? Explain all the hardware components of a computer and describe in the diagram?

7) What is Database Management System? Create an ER Diagram with many entities for any domain of your choice?

Description of problem area

You are to create a database for an online bookstore. The bookseller also wants customers to be able to create an account on the site. Books must be registered without VAT but an order must show the price without VAT, the amount for VAT and the total amount. The VAT for books is 6%. User Stories As a bookseller, I want to be able to see a list of books and who/who wrote them. As an author, I may have written or co-authored several books. As a bookseller, I want to know a book's title, price, number of pages, which author(s) wrote the book and a brief description of the book. As a bookseller, I want to know the respective author's name and a brief description of the author. As a bookseller, I want a book to be written by one or more authors. As a customer in the bookstore, I want to be able to register an account. As a customer, I register my account with my e-pot address. As a customer in the bookstore, I want to be able to place an order for one or more books. As a bookseller, I want an order line to consist of which book and number the customer bought. As a bookseller, I want an order to be linked to a customer and the date the order was ordered. As a bookseller, I want each book to have a unique ISBN number. As a bookseller, I want every book to be stocked without VAT. As a bookseller, I need to be able to see orders with a total, with and without VAT (book VAT is 6%) and who placed the order. As a bookseller, I need to be able to see all orders and associated order lines.

The password should be at least 9 characters long.

The password should contain at least one uppercase and at least one lower case letter.

Questions 388

Write a program that will accurately determine a bill. Programs must be tested. In order to test this program, use the following scenario. A family stops at the restaurant for lunch. The family is composed of a middle aged mother and father named Bill and Nancy. They have a 2-year old child named Jesse. They are traveling with Nancy's elderly grandmother, Sarah. Everybody decided to order a burger. Nancy and Jesse order a soft drink. Nancy and Sarah order soup. Bill orders 5 wings. Bill and Sarah order coffee. Jesse orders ice cream. Run your program one time for each person and determine the grand total this family would owe on their bill

For example, used $30,000.00 for a car and $8,000.00 for a motorcycle.

In the main method, declare an array of 10 vehicles that each vary in cost. You can combine cars and

accessing each vehicle’s getPrice() method.

Questions 390

large particles,

20%

drug. The solution is centrifuged to remove the large particles, then sent to a filter to remove small particles, and finally sent to an evaporator to remove excess water. The final solution to be bottled is

75%

drug,

L=

= water). a) Determine the flow rate of the solution to be bottled if the flow rate into the bioreactor is 250

kg/h

and the other two sides are

a

2

=a

c

2

The triangle is obtuse if

c

2

You are asked to write a program in which the user inserts the lengths of any triangle's three sides. Based on the inserted values, the code outputs a statment that states the triangle classification according to its sides followed by the triangle Example: If 8,9 , and 3 are inserted as sides' lengths, the output will be: scalene obtuse This is because the three sides are diffent in their lengths and

+3

2

, the code shall assume that the negative values are positive and give out a normal output. Write a C++ program that opens a file named data.txt which contains data written in three lines. Each line starts with a letter followed by three double floating-point values. The program should output the data in table format such that lines are ordered in the table alphabatically according to the letters they start with. If the letter is an uppercase, it must be converted to its equivalent lowercase letter. All letters must be displayed in lowercase format. Notice that the width of the first column in the table (which contains the letter) is 5 and it is aligned to the left. All remaining columns have width of 10 and their data is aligned to the right. Also Notice, that all the numbers in the table must be displayed with exactly three digits to the right of the decimal point. After prinitng the table, the program must display the following statistics values (computed for all floating point values read from the file) on one line with exactly one space between each two of them, as follows: Average Standard_deviation Maximum Minimum Statistics values must also be displayed with exactly three digits to the right of the decimal point. Equation for computing the standard deviation is:

σ=

−μ)

2

standard deviation

N=

=

each value from the set

Questions 394

Write a Simulink Block to check whether a number is divisible by 6. - Write a Simulink Block that will input number and display 1. If the number is negative or positive number 2. If the number is odd or even number

r1,S1

and

=0

- If

=2∗

(SectorACF

(r1,d,r2)//

angle1 - SectorArea

//

the area of Sector ACF Please implement the following functions: 1. sectorArea(angle, radius) : compute the area of a sector given the angle and the radius 2. circleArea(circle) : compute the area of a circle given the circle struct 3. triangleArea(includedAngle, side1, side2): compute the area of a triangle given two sides and the included ang le 4. angleoftriangle(side1, side2, side3): compute the angle of a triangle opposite to side 3 5. intersectionarea(Circle

sin(),acos(),sqrt()

in math.h The input has two lines, one for each circle. The format of each line is, which are the

x−y

coordinate of the circle ce nter and the radius.

Input Validation: Do not accept an amount that is less than 0.

Your code should implement at least two functions. This style of programming should apply to all your future programs. Points will be deducted otherwise.

11. Consider the processes introduced in this chapter. Which ones give you the most flexibility to change in reaction to changing requirements?

12. Suppose Amalgamated, Inc., requires you to use a given process model when it contracts with you to build a system. You comply, building software using the prescribed activities, resources, and constraints.After the software is delivered and installed, your system experiences a catastrophic failure. When Amalgamated investigates the source of the failure, you are accused of not having done code reviews that would have found the source of the problem before delivery.You respond that code reviews were not in the required process. What are the legal and ethical issues involved in this dispute

b.Convert the following binary IP address to dotted decimal form as shown in module 5. Show your working; failure to do so will only gain under half marks.

01100011.01000010.00100001.00000001

Questions 400

13 of 28 C

Select only one answer.

A. Modify the Access control (IAM) settings of the zone.

It's not a coding question, please do not copy and paste random thing for other answers, Thanks!

Questions 402

Questions 403

[[ USING SQL ]] The Mobile for You Case Study

In view of the fact that the shop has been so busy meeting the high level of sales, as this is what earns money, they have neglected to develop an adequate internal system for monitoring the products. Ideally Dave would like to be able to have a system which could very easily provide him with answers to both product information queries and also queries about the sales process itself.

Some of the product information queries could be as follows:

Q4. details of sales that are handled by an individual salesperson.

Q5. list of tablets which have been sold on a particular day.

Questions 405

14 of 28C

Private IP address: 10.10.1.5

Public IP address: 168.61.186.27

C. PTR resource record for 10.10.1.5

D. PTR resource record for 168.61.186.27

G=(N,A)

with arc costs ciij for each arc (i.j) contains no negative cost cycle. In this network, let

i,j)

without creating any negative cost cycle, assuming all other arc lengths are held constant. Describe an efficient algorithm for determining

Questions 408

All-Pairs Shortest Paths In the lectures, we've seen Dijkstra's algorithm for finding the shortest paths from a given vertex to all other vertices in the graph. The Floyd-Warshall algorithm for finding the shortest path between all pairs of vertices works as follows: Given a graph

- for each vertex

(u,v)=ϵ∈E

, dist

k∈V

: - for each vertex

[i][j]>dist[i][k]+dist[k][j]

:

CAN YOU INCLUDE THE OUTPUT PLEASE

THE SUBJECT IS IMMEDIATE JAVA

Subnet2- has an IP address range of 192.168.2.0/24 and does NOT have any VMs connected

You need to ensure that you can deploy Azure Firewall to VNET1.

C. Modify the subnet mask of Subnet2.

D. Modify the IP address space of VNET1

, create a static array of linked lists that will use constructive chaining based hashing to insert 7 words that begin with each letter. Your program should ask the user to input a string beginning with any of the first seven letters, uses the hashing algorithm to detect which slot this string be inserted into. Should there be a collision, the string will be added as a node to the linked list. Optional This part of the question is optional. Should it be successfully completed, a bonus of 5 marks will be awarded on top of this assignment. Again, no help should be received from third parties otherwise a score of zero will be awarded on this entire question. Write a search method that will allow the user to search for a string entered into the hash table. Should the string be successfully located, the method will return true, otherwise, false.

Questions 412

, and you need to find two positive integers

X

X&Y&2

N

&

denotes bitwise AND operator) -

X

exists, print

−1

if no such value exists. Assumptions -

(X,Y)

include

X

provided in the editor. This function takes the following 2 parameters and returns the required answer: -

K

: Represents the value of

T

also specifies the number of times you have to run the findSmallest

K

. Output format For each test case in a new line, print a single integer representing the answer. Constraints

0≤K≤10

9

N=2

-

N=4

-

X=16

is the smallest value satisfying the conditions, so the answer is 16. The third test case Given -

(X,Y)

with a difference of 8 , so the answer is

24.1

in our textbook TestMyCircularL inkedList.java - a test program for the class that you will create Your task is to create a class MyCircularLinkedList

(Ee)

, indexOf(E e), and lastIndexOf(E e) methods are never passed null as a parameter. Testing your solution: Once you have completed MyCircularLinkedList, you should be able to run the main method in TestMyCircularLinkedList.java and receive a report that forty-four tests therein are successful: (1) [America] Test 1 successful (2) [Canada, America] Test 2 successful Test 43 successful Test 44 successful Required tests completed Of course, you are welcome to run additional tests on your solution. What to turn in: Submit you MyCircularLinkedList.java file on Canvas. Include your name at the top of the file, as well as a brief description of what the code does. *CilUsers\daist\Downloads\MyList.java - Notepad++ File Edit Search View Encoding Language Settings Tools Macro Run Plugins Window ?

n

matrix of non-negative distances, and one is required to compute the shortest path between every pair of nodes. Instead of using the Floyd algorithm, one can use the Dijkstra algorithm for every pair; call this the "every pair" Dijkstra algorithm. (a) Write down the run time for the Floyd algorithm. (b) Write down the run time for the "every pair" Dijkstra algorithm. (c) Compare the the run time in (a) and (b).

Questions 416

Write a C program that: 1. Read the title, authors, journal and published year of an article 2. Create the Article struct holds all the above information 3. Print the Article using print_format_full(Article) 4. Read and update the title 5. Print the Articleusing print_format_simplified(Article) Hint: You cannot use scanf() with \%s in this exercise, due to the spaces. You need to use fgets() instead. And pay atten tion to the newline '

Questions 418

Task 2 (s marks) Querying and manipulating data in HAase table Consider a conceptual schema given below. The schema repoesens a simple database domain where stodents submit assignments ard each submission consists of several files and it is related to one subject. Download a file task2. hb with HBase shell commands and use HBase shell to process it. Processing of cask. hb creates HHase table cask2 and loods some daca into it. Use HBase shell to implemen the following queries abd daca manipulations on the HBase table created it the pervious step. Save the queries and data manipulations in a file aolut.ion2. hb. (1) Find all informotion abous a student number 007, list cone version per cell. (2) Find all informonion abous a submbsioe of assignment 1 performed by a sudent 007 in a subject 312 , lise ose version per cell. (3) Find the first and the last armes of all students, list one version per cell. (4) Find all information aboun a student whose last name is Porter, list oee version per cell. (5) Delete a column family BILES. (6) Add a column family ENMOLMEN2 that coerains information about dates when the subjects have been emsolled by the saudenss and allow for 2 versions in each cell of the column family. (7) Insert intormacion about at least two eneolments performed by the studeats. (8) L.bs information about all enrolmenss performed by the studeass. (9) Increase the boeal number of versioss in each cell of a column family ENBCLMEMT. (10) Delete HBase takle task2. When ready, start HBase shell and process a scripe file solut.ion 2 , hb with Hbase command shell. When processing is complesed copy the coetens of Command wiadow with a listing from processing of the script and paste the results into a file aolution2. rpt. Save the file. When stady submit a file aolution2 . xpt. Deliverables A fale golution2,xpe with a listing from processing of a script file aoluthon 2 , hb.

+

or - the textbox become empty to enter the second number, for sure when = button pressed the result appear in the richTextBox. Also, there are two buttons which are

C

to remove one digit from the entered number, and

{1,2,…,n}

, where

n

? c) that assign 1 to exactly one of the positive integers less than

1. Create a superclass called Product. The Product class should implement the following methods:

__init__(self, name, price, discountPercent)

returns the discount price of this product

getDescription(self)

getDescription(self)

overrides the getDescription() of the Product class by returning a string that’s concatenating the string that is returned by the getDescription() method of the Product object with “by” and the instance variable for author of the Book object.

II. The following image represents a master slave D-Type flip-flop

III. JK flip-flop is similar to SR flip-flop in which S is replaced by J, and R is replaced by K. The only difference

Note: Remember that in SR flip flop if S and R become 1 at the same time, the circuit enters invalid

state. In JK flip-flops however, if J and K become 1 at the same time, toggle state occurs. Toggle state is

V. The following circuit represents a 2-bit JK flip-flop counter. The JK counter relies on toggle state like T-

counter.

note: using StdDraw library.

Thanks

P

have in common. Being the savvy computer scientist that you are, you've stored your hobbies into a list of strings and

h1

and

Questions 426

2. You're on an exciting sloth-studying expedition in Central America, and you've been maintaining data on how many sloths you've sighted each day. This data can be stored into a list for example, the list

n

is an integer. Here are some example arguments for this function and their expected return values: (b) (5 points) Write a function average_threshold(data,

n

is an integer. If there are no such days in the list, the function should return None. Here are some example arguments for this function and their expected return values: c) (5 points) Below your function definitions in sloth_studies.py, write a program that does the following: - Get user input for how many days of sloth sighting data to enter. Include input validation with a loop to ensure that this value is at least 1. - Get user input for how many sloths were sighted on each day, and store that data into a list. Include input validation to ensure that each value is non-negative. - Get user input for the threshold (the value of

Must enter at least one day of data! Try again:

4

Enter number of sloths sighted on day

2:

13

a.

fraud

d.

breach of contract

patent

c.

oi.e. if the user enters an ID that is already in the file, then the ID and name should not be added again. Hint: you may use an array to store students' IDs. Before adding any new ID, you should check first if it already exists in the array or not. Write a Java program that: - Asks the user to enter the ID and name of 10 students. (Scan from keyboard) - The program should write the students' data (ID and name) into a file named "Student.txt" as comma separated lines. - The file should not include redundant IDs. (No duplicate IDs allowed).

Questions 429

a disk named Disk1

a virtual network named VNET1

B. VM1 and Disk1 only

C. Disk1 and IP1 only

and

41.969

in Net Income. 7 A data table with conditional formatting will help to better visualize the expenses, revenues, and net income of the business. Fill in the Expenses, Revenue, and Net Income cells (range G4:14) and the complete the data table using the range F4:I19. 8 Format the range G5:119 as Currency. 9 Copy the information in range A3:D18 from the Break-Even Analysis worksheet and paste it in range A4:D19 on the worksheet PriceAndGuest. Keep the source column widths. 10 Create a data table in the range F5:N22. The price (row 6) needs to start at

$4

increments, and the number of guests (column F) needs to start at 35 and increase in increments of 5 . Be sure to add a reference to cell D19 in cell F6. 11 Format the data in the data table so any net profit under

−$5,000

will have a light yellow background and dark yellow text, and anything greater than

$5,000

Write an assembly language program for PIC microcontroller to transmit the message "YES" serially at 9600 baud, 8-bit data, and 1 stop bit. Do this forever (continuously, without ending the program).

Questions 433

Bieber, Justin 96 72 85 83 54 77 90 62 Top6Avg: 83.8

Your program must define a function to determine the average of the top 6 marks. You may define more functions as needed for your program.

annotation. You can find the specification here:

http://www.sequenceontology.org/gff3.shtml

Within the feature table another column of note is the 9 th , where we can store any key=value

pairs relevant to that row's feature such as ID, Ontology_term or Note.

(column 9). When it finds this, it should use the coordinates for that feature (columns 4, 5 and 7)

and the FASTA sequence at the end of the document to return its FASTA sequence.

header which matches their query, like this:

>gene:ID:YAR003W

test runs with 3 features which are present in the file and 1 where you intentionally enter a

feature NOT present in the file. Your script should handle this gracefully

Questions 437

Your program will include: 1. a button for the user to request a taxi; ( 20 points) 2. a text box to display the dispatched taxi information; (20 points) 3. a button to generate daily end-of-shift report; (20 points) 4. a text box to display the end-of-shift report; (20 points) 5. necessary label(s) to provide information (such as company name, instructions, etc.) (20 points)

N=M+A

. Deduce the values of subfunctions

Y

from the following circuit diagram. Carry from 2 previous least significant bits. The following SR latch is in Reset state (with

(afterS−1,R−0)

(after

S

to 0 (b) Change

S

and

R

at 0

that calculates the sum of the numbers 1 to n (where integer n is a parameter of the function).

The function can be in Java.

(using the order

2

A

G

(c) Use part (b) to find the number of paths of length 2 from

v

2

to

v

Apply a weak heap sort algorithm to the following array:

2 16 27 19 11 5 33

1. Size of each group in pivot selection (at least 3, at most n)

2. Number of elements in the sequence

Use the program to collect the performance of group size = 3, 5, 7 under different input size and plot them in one chart. Explain the chart in a report.

1. Start with Random Select, (textbook 9.2 and 7.3)

6. modify the code to accept any group size

NOTE: Expert please provide sample output for verification of code.

Currency will be formatted with a dollar sign, comma separation for thousands, and to 2 decimal places.

You should perform at least the following tests:

5. Click the Clear button. All textfields will reset, radio buttons and checkboxes will be unselected. The GUI will appear as it did when you first launched it.

6. Click the Exit button. The GUI program will terminate and the window will close

and the function

f:X→X

. Using the notation

f

x

times, write down explicitly the following functions:

f∘f∘f[2

marks]

f

(624)

Please help I am stuck and don't know what to do

**I JUST NEED THE MAIN.C FILE PLEASE USE GIVEN CODE ONLY**

ContactNode* GetNextContact(ContactNode* thisNode);

void PrintContactNode(ContactNode* thisNode);

ContactNode* nextNodePtr

(2) Add the following functions:

GetNext() - Accessor (1 pt)

PrintContactNode()

(2) Define main() to read the name and phone number for three contacts and output each contact. Create three ContactNodes and use the nodes to build a linked list. (2 pts)

Note: End the last input line with a newline.

410-555-9385

Rachel Phillips

Person 3: Rachel Phillips, 310-555-6610

(3) Output the linked list using a loop to output contacts one at a time. (2 pts)

Name: Juan Alberto Jr.

Phone number: 410-555-9385

#include <stdio.h>

#include <string.h>

int main(void) {

/* Type your code here. */

300

branches within the country, and more than

Question IV: A class called Customer, which models a customer in a transaction, is designed as shown in the class diagram. A class called Invoice, which models an invoice for a particular customer and composes an instance of Customer as its instance variable, is also shown. Write the Customer and Invoice classes. Write a test program that will generate at least 2 Customer, 3 Invoice instances, and test each method that you write.

Questions 449

. A disproof should be performed by demonstrating a relation that satisfies the conditions and functional dependencies in the left-hand side of the inference rule but does not satisfy the dependencies in the right-hand side. Prove: a.

{X→Y,X→W,WY→Z}∣=X→Z

d.

{X→Y,Y→Z}∣=X→YZ

is a subset of

Y}∣=X→Z

i.

{XY→Z,Z→X}∣=Z→Y

Questions 450

I am trying to complete the following sub task, but I could not be able to get it. Please help me out.

// Declare class name

class pixel;

public:

float x;

class icon {

public:

void showPixelDetail(const pixel & aPixel) {

cout << "\nCoordinate = (" << aPixel.x << ", " << aPixel.y << ") with brightness = " << aPixel.Brightness << "";

cout << "\n\n--------The detail contain in icon are---------\n";

for (int i = 1; i <= aicon.idNumberOfPixels; i++) {

// Hide the details of pixels so to not clutter the main code

void initialiseAsDefaultDiagonalLine(icon &myIcon) {

myIcon.thePixels[2].x = 2;

myIcon.thePixels[2].y = 2;

myIcon.thePixels[4].x = 4;

myIcon.thePixels[4].y = 4;

myIcon.thePixels[6].x = 6;

myIcon.thePixels[6].y = 6;

}

int main() {

myFirstEverPixel.Brightness = 3;

cout << "\n------The detail of myFirstEverPixel are-------\n";

aPixel.x = 3.9;

aPixel.y = 4.1;

// Create an instance of a pixel called pixelOne and pixelTwo

// Test if the code will understand "=" sign by printing the output of pixelTwo

pixel pixelTwo;

pixelTwo = pixelOne;

icon myIcon;

initialiseAsDefaultDiagonalLine(myIcon);

300

branches within the country, and more than

Sub Task Specification: Design and implement the top-level object in our software solution which is to be an instance of a radarDisplay class. A radarDisplay instance “refers to” a number of icon instances. We don’t know how many icon instances it will actually need to hold so must allow this to be variable; but we are prepared to limit this to 100 in the code. A further complication is that different people in the airport control tower will be looking at different instances of radarDisplays, that show different regions of the airspace and if a particular air vehicle appears on multiple displays, they must share the same icon instance that represents it.

Here is my code:

class icon;

// Develop a class to encapsulate the data associated with the concept of a graphic pixel

float y;

float Brightness;

int idNumberOfPixels; // integer to hold the id number

pixel thePixels[16]; // Contain up to 16 pixels

}

// Function passes an instance of an icon as it's argument, and use the showPixelDetail function to list the details of the icon's pixel

cout << "\n\nPixel " << i;

showPixelDetail(aicon.thePixels[i]);

myIcon.idNumberOfPixels = 7;

myIcon.thePixels[1].x = 1;

myIcon.thePixels[2].Brightness = 15;

myIcon.thePixels[3].x = 3;

myIcon.thePixels[4].Brightness = 15;

myIcon.thePixels[5].x = 5;

myIcon.thePixels[6].Brightness = 15;

myIcon.thePixels[7].x = 7;

// Test if pixel object was correctly implemented

pixel myFirstEverPixel;

showPixelDetail(myFirstEverPixel);

cout << "\n-----------------------------------------------\n";

aPixel.Brightness = 7;

cout << "\n-----------The detail of aPixel are------------\n";

pixel pixelOne;

pixelOne.x = 4.4;

cout << "\n---------The detail of pixelTwo are------------\n";

showPixelDetail(pixelTwo);

showIconDetail(myIcon);

}

4,000

employees. Computers, at the FBC have many different technologies, platforms, and operating systems. The bank has workstations and data-store-houses also and it will be able to communicate remotely. The data must be secure even if users are scattered all over the country. Base Security System must installed in the central workstation and some modules of the system can access only by a select group of employees at the IT and Ops department. This system includes modules such as administration, conventional banking, Islamic banking, SME banking, Cards and SWIFT services, Foreign exchange and remittance section, loan and advances, and payroll. You have asked to develop a software system for managing the resources aspect of the FCB. a) What is the architectural solution model for the system? b) What is the business problem and how will you address this requirement? c) Draw the architectural diagram for this business setting according to business requirement and describe it.

------------

<!DOCTYPE html>

rel="stylesheet"

href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.14.0/css/all.min.css"

</script>

</head>

</div>

<div>

</button>

<input type="color" list="presetColors">

</datalist>

</body>

The project aims to combine topics of electrical-electronics engineering (EEE) and computer engineering (CoE) for the design of an autonomous car that can identify simple signs on a given track and then make a decision to speed up, speed down, or to stop. While moving, the autonomous car is expected to move according to the mathematical models that you will develop. The autonomous car is expected to stay in its track without crossing to the next lane.

[Project Methodology] In a brief, describe your approach for the project to be successful. State clearly how you will need to complete your project. Add a block diagram like the one below to this section to identify the top-level view of your project. The block diagram also helps you to develop your schedule. Show the relationship between block diagrams and how they will be integrated with each other. Explain how you will use modularity and abstraction in your design.

Imagine you are a software architect at First Bank Corporation (FBC). The bank has

300

hello, I know the project is too big but please, can you write it using array.. java language it is due soon

Questions 458

const notes = JSON.parse(localStorage.getItem("notes"));

if(notes){

addBtn.addEventListener("click", () =>{

addNewNote();

note.innerHTML = `

<div class="notes">

<div class="main ${text ? "" : "hidden"}"></div>

<textarea class="${text ? "hidden" : ""}"></textarea>

const main = note.querySelector(".main");

const textArea = note.querySelector("textarea");

textArea.classList.toggle("hidden");

});

textArea.addEventListener("input", (e) =>{

const { value } = e.target;

}

function updateLocalStorage(){

});

localStorage.setItem("notes", JSON.stringify(notes));

(USE CASE 1 INFO)

Questions 460

Do you need a taxi?

Y

……

……

19 Calls 25 Calls 10 Calls 12 Calls 22 Calls 13 Calls

25 Passengers 45 Passengers 34 Passengers 29 Passengers 24 Passengers 30 Passengers

1

2

1

3

2

Decide whether

S

program to keep the records of the price of items in a store. The information of each item contains item price. Consider in the program, a one-dimensional array to save the item price. The name of the array is "Price" followed by the value of your AUM ID. If the AUM ID of the student is 12345, the array name will be Price_12345. (2 points) The size of the array should be equal to the numbers of letters in your first name. If your first name is "xo", the value of SizE should be 3. (2 points) The values of the arrays' elements (Price_12345(i]) represent the item's Price with item 10's equal to the value of the index "7." It is not allowed to store your iD or name in a variable. 1. Define a function that performs the following: - The name of the function is "Calculation" followed by the value of your student ID number. For example, if your student ID is 12345 , the name of this function should be Calculation_12345, (3 points) - The function takes an array that represent the Price of items as formal parameter. (3 points) - The function prints the name of the function using your name and iD. For example, if your name is "xox

Wr

if your AUM ID is an even number and

N=25

. (20 points) 2. Write a main function to do the following: - Define a one-dimensional array that represent the Price of items, Initialue the array by reading values from the user as shown in the sample output. (5 points) - Call the function Calculation. (10 points) Output format - (3 points) Sample output (ff the student name is xox byy and D

=12345

Inter the Price) 12 Inter. Iten with

10.2…

Question 4 1 pts What symbol is used for a Boolean OR operation 86 What symbol is used for the Boolean NOT operation

8&

Question 8 What is the major difference between a while loop and a do-while loop the do while loop is more etficient. there is no difference a do while loop will always execute at least once, the do loop is more efficient What mathematical symbol means "greater than or equal to" Question 10

• Define a metric “awareness” in unambiguous terms

• Describe a set of partners and associated protocols such that the system is aware of the human’s awareness at all times

[1,2,4

,

=[3,7,1,4,6,6]

of length

which causes a penalty of 1 . Note that there are other possible sequences as well but 1 is the minimum penalty. Function Description Complete the function minPenalty in the editor below. minPenalty has the following parameter(s): arrlarr[0] ...arr

[n−1]]:

1≤n≤10

4

Questions 466

24 of 28C

Select only one answer.

A. General purpose (D-Series)

Questions 467

oblem 2 [35 points ] Calculating student grades. This problem requires you to read data from several files (containing numeric scores on homeworks, quizzes, and exams for students in a course), use a dictionary to collect information from the data in those files, and finally to write a combined course grade roster into an output file. Evaluation criteria for the course are described below: 1. Four homework assignments are handed out. Each homework is out of 100 points. The lowest homework score is dropped, and the remaining three scores determine the final homework score. The homeworks are worth

40%

of the final grade. The final total score is simply the sum of the combined homework score (out of 30), the combined quiz score (out of 30), and the final exam score (out of 40), each calculated as described above. All scores are real values. The letter grade is determined according to the usual scale: A final total score of

B+,80.0

or higher is a

C,60.0

or higher is a

F

. The data for this course is available in four separate input files: 1. A file called "studentids.txt" that contains simply the list of identification (ID) numbers for the students in the course with one entry per student. Each line of the file contains just an ID, which is a string of characters in the usual format

Questions 468

If avialible can you please provide the time and date on the screen shots so i can make sute its legit

b

j

j=min(i,k)}

. Prove that

You have an Azure virtual machine named VM1.

VM1 contains the following:

You plan to resize VM1.

What is preserved after the resize?

D. File1, File2 and the state of App1 only

E. File1, File2, the state of App1 and the connection of User1

Dominos component:

This is the domino that is blank on one side and is flipped to reveal the pips.

>>

Random Sentences The purple horses fall merrily

2) 1NF,2NF,3NF or BCNf? Identify the best normal form

3) If the relation is not in BCNF, decompose it to BCNF. Make sure to identify a new relation and keys during each step

Critically read, and analyze the scenario and Prepare a PPT presentation with six slides and including the following contents:

Introduction.

Question 1: [10 POINTS] You are hired as a developer by the director of admission and registration at a Jordanian university to write a Python program to manage students' registration in the available courses. The required program must do the following: A. [0.5 Points] Requests that the user enter the number

N

,25,[]],(139208,1):[ ’oop 2

ose 1 is

oc | NOTF: You should call the calculate total regiteredStudenss function. D. [1.5 Points] Write a function named mgiver_sfudent that accepts the sfudentiD, the scheduledCourses dictionary, and a fuple of course id and section. For cach entered student id and the tuple of course id and section do the following i. [0.75 Poiats] The scheduled courtes dictionary is used to retrieve the copoclty and compute calculate reghtered students for the entered course id. ii. [0.5 Points] If the fotal number of reglstered studentr is less than the capacio; add the studentID to the lit of regivfered stadentr. ii. [0.25 Points] Finally, retarn the scheduled courses dictionary. E. [1 Point] Write a function named anregikter_stadent that accepts the stadent id, the scheduled Courses dictionary, and a tuple of course id and section. For each entered shadent it and the fuple of course id and section do the following i. [0.75 Points] if the student id exists in the list of registered students of the entered course id, remore the student id from the list of reghtered students. ii. [0.25 Points] Finally, retum the scheduled courses dictionary. NOTE: You should call the calculate, fotal registeredStudents function. D. [1.5 Points] Write a function named register_studenf that accepts the stadentl., the secheduledCourses dictionary, asd a twple of course id and section. For each entered student id and the tuple of ceurse id and section do the following: i. [0.75 Points] The scheduled courser dictionary is uned to retrieve the capacity and compute calculate registered studenes for the entered ceurse id. ii. [0.5 Poiats] if the folal namber of registered studentv is less than the cepacify, add the studeniID to the list of regivtered stadents. [0.25 Foints] Finally, retum the seheduled courser dictionary. F. [1 Point] Write a fusctios bamed unreghter_student that accepts the student id, the scheduledCourser dictionary, and a tuple of course ld and seclion. For each entered student id and the taple of course id and section do the following? 1. [0.75 Points] If the shudent id exists in the list of reglstered sfudents of the entered course it, remave the student ad from the list of reglatered studenes. ii. [0.25 Poists]

(a) Give eight different examples of trees that have exactly three leaves.

(b) Give an example of a tree that has 10 vertices, nine of which are leaves.

If your answer is YES then draw G. If your answer is NO then prove that s cannot be the degree se-

quence of any graph.

EMPLOYEES According to the above table, write queries for the questions below. QUESTION 1: List names and surnames of all employees together with the year in which they were born. The list should be ordered with respect to names in ascending order. QUESTION 2: List names, surnames, and the salaries of the employees who do not live in Erenköy. The result should be ordered with respect to salaries in descending order. Note: Addresses may appear in English or Turkish characters. QUESTION 3: List names, surnames, departments, and ages of the male employees who are older than 40 and live in Bostancı or Levent. Order the list with respect to their ages in ascending order. QUESTION 4: List names, sumames, and salaries of the employees who were born between 1960 and 1975 and are working in departments 1, 2, or 3. Order the list firstly with respect to salaries in descending order and then ages in ascending order. QUESTION 5: List names, surnames, departments, and tax paid by employees whose net salaries are greater than 2000 and surnames come after "Gazi". QUESTION 6: List names, surnames, and departments of male employees who were born after April and female employees who are older than 45 . The list should be in alphabetical order with respect to surnames.

Questions 479

<

source file-n>< > - Program concats (merges)

Questions 481

Design a 2- bit storage register and indicate the input, output, and data on each line for the LOAD condition.

a File named File1 that is stored on volume C:\

a File named File2 that is stored on volume D:\

Select only one answer.

A. File1 only

Questions 483

Construct a shift register to perform right to left shifting. Using the constructed register, indicate the number of cycles required to LOAD, READ, LOAD and READ

Questions 486

PLEASE SOLVE ALL QUESTIONS USING THIS WORD FILE. QUESTION 1: [4 POINIS] A) Consider the following strings and then compute the result of the following operations:

2

s

1

3.

S

K

s

2

2

=

5.

L2

be languages over the same alphabet. Identify three possible scenarios, based on the strings in

L1L2=L2

. consider the following NFA M. Check if the following strings belong to the

={x

byaz:

={w:w∈

doesn't have aa as substring

}

w

have even number of a's and odd number of b's

points] QUESTION 5: [5 POINTS] Convert the following NFA to an equivalent DFA:

Questions 487

int i = 0;

for(int i = 0; i < size; i++) {

}

Questions 489

matrix to the user for selection. Individual items may vary in cost, but will be one of the following (

$0.50

- Give a real example with a full scenario that we must use Decorator Pattern (not the example discussed in the book or lab).

- You must highlight all the possible problems that might occurs if we don't apply the pattern.

base on the picture above, write an explanation about the insertion sort

Questions 492

C

determines how many champions are created. It will use createChampion() and addChampion() to create and return the head of the new linked list. - void printChampionlist ( Champion *head) - This function traverses the linked list that head is pointing at and will print out the entire list of champions for a given player. Example: S6 M5 F4 S4 T3 - Champion* removeChampion ( Champion *head) - This function removes and deallocates the first node in the linked list that head is pointing at. It returns the new head of the linked list. - Champion* destroyChampiontist ( Champion *head) - This function is the destructor for a linked list that head is pointing at. It will remove all the champions from the player's list and return NULL. TASK 3: Complete the main. c - The program will accept one additional command line argument, which is the number of Champions each player will start with. Your program must determine if there is this command line argument: - If the command line argument does not exist, print an error, and end the program. - If the command line argument, check to see if it is a number greater than 0 . If it is not, print an error and end the program. - Build each player's Champion linked list based on the size passed in through the command line - Start the game loop. The game continues so long as both players have Champions to battle with. In each turn (iteration of the loop): Print out the round number starting at 1. - Print out each player's Champions using printChampionList(). Implement the outcomes for each permutation of Champion roles. There are 16 permutations of (MM, MF, MS, MT, FM, FF, FS, FT, SM, SF, SS, ST, TM, TF, TS, TT). - Using the table for battle outcomes, decide who wins / losses, and implement the reward / punishment on both players. For this, you will need to use the functions createChampion(), addChampion(), and removeChampion(). - Remember that at the end of each turn, the champions already deployed in the battle will be removed from the players' lists BEFORE implementing the reward / punishment based on the battle outcome. - Print the outcome for the battle and move to the next round. - At the end of the loop, there will be either a tie (i.e., no player has any champions left) or one player who wins (i.e., still has champions). Determine and print this final outcome of the game. - Remember to empty the entire list of champions for the players by freeing the memory for the linked list, before ending the program. Task 4: Create a makefile Create a makefile to compile and link all the files together. The grader will compile your code using yourmakefile. The name of the executable must be project3Exe Submission Be sure that your code follows the class coding style requirements. Your output should be similar in format as compared to the sample output shown below. Create a folder named your abc123, place all program files in this folder. Zip the folder and submit this abc123.zip file. Rubric [6 points] - General Requirements [2 points] - coding style - proper comments, indentation [2 points] - correctness - compiles properly and gives correct output [2 points] - submission - no missing files, zip, properly submitted [2 points] - makefile [2 points] - make compiles and creates the executable with the correct name [4 points] - champion.h [4 points] - header guard, enum, struct, function prototypes [20 points] - champion.c file [4 points] - createChampion() [5 points] - addChampion() [3 points] - buildChampionList() [2 points] - printChampionList() [3 points] - removeChampion() [3 points] - destroyChampionList() [18 points] - main.c [2 points] - command line argument validation [2 points] - build initial linked list for each player [2 points] - set up the game loop to continue playing until at least one player has Champions [2 points] - print out descriptive information for each round [8 points] - implement the functionality for each of the 16 permutations [2 points] - determine and print out the final outcome, free memory, and end program \#\#\#\#\#\#\#\#\#\#\#\#\#\#\# RUN-1 \#\#\#\#\#\#\#\#\#\#\#\#\#\#\#

>./ project3Exe 5

Player 1 is a FIGHTER and Player 2 is a TANK Player 1 (FIGHTER) wins and gains a new champion. Player 2 (TANK) loses but with no penalty.

============

GAME OVER

=============

GAME OVER

=============

Questions 494

The size of the code for the project in KLOC (kilo lines of code) is 1024. Project manager hires some developers. Their analytical capability is very high but experience in programming language is low. Surprisingly they have a very little experience on virtual machine. Calculate the effort (E) and scheduled time for development (D) according to cost drivers table for embedded type project.

z;

y=y+1;

x+1;

Questions 496

when randevur is clicked it goes to another page

The ui is that of the home page

÷0100

(b) The algorithm shown in Algorithm 1 shows the psuedo-code for a simple divide algorithm. Write a assembly code that implements this algorithm. This code should be able to be ran in MicSim. Therefore, your implementation should use the

68 K

at the completion of each loop iteration. (d) The current algorithm does not deal with the "Divide-by-0" error. What would happen if

j=0

-question multiple-choice exam (for

n

-characters string of the correct answers. Then each input contains a long integer student ID followed by a space and then that student's answers. If the user chooses to input the data from a file, then the first line in the file should contain an integer representing the number of exam sheets (students), followed by another line that contains the number of questions (

n

What are the characteristics of randam forest classification model? What is the difference between random forest model? Give the pseudo code of it. Explain the code.

Questions 500

Task 2: The InstantRide Management team considers setting up a Lost & Found inventory. In order to start the setup, the team requires the detail of users with their travel start and end times. The team wants to track potential list of users who may have forgotten their items on the cars. Therefore, you need to return USER_FIRST_NAME, USER_LAST_NAME, TRAVEL_START_TIME, TRAVEL_END_TIME information from the USERS and TRAVELS tables connected inside a JOIN statement by the USING function and USER_ID field.

Questions 502

5)

0.256

Accuracy

=1%)

Questions 506

Table 1: Cost drivers \begin{tabular}{|l|l|l|l|l|l|l|} \hline Cost Drivers & Very Low & Low & Nominal & High & Very High & Extra High \\ \hline AEXP &

1.00

&

0.78

\\ \hline LEXP &

1.00

&

Questions 508

This python program of mine does a knight's tour of an NxN chessboard and finds one possible solution

x = int(input("X = "))

y = int(input("Y = "))

def printSolution(n, board):

for i in range(n):

# Initialization of Board matrix

board = [[-1 for i in range(n)]for i in range(n)]

move_y = [1, 2, 2, 1, -1, -2, -2, -1]

board[x][y] = 0

print("Solution does not exist")

else:

# Try all next moves from the current coordinate x, y

for i in range(8):

if(solveKTUtil(n, board, new_x, new_y, move_x, move_y, pos+1)):

return True

solveKT(n,x,y)

endtime = datetime.datetime.now() - startTime

Questions 509

4. Suppose you have a set

2

n−1

, you can find a subset of

W

(in screen space), find the depth of the plane at pixel

(4,4)

, determine if the particle's color or poly's color will be displayed at this pixel d. (10 points) Explain in brief how z-buffer algorithm handles penetrating polygons and cyclic polygons that Painter's algorithm has difficulty with

Questions 511

should return 3 (since the leftrnost two bits of 11001000 is 11) and get most_stgnificant

2(150)

Problem Statement Consider a 'd-block dlagonal' matrix, which is a square matrix made up of smaller square matrices along Deliverables the diagonial, with zerrs everywhere else as shown in the figure below. It has

i

2

. The elements in the

d=3

). function called BiockD a agonalsolver, and the supplied Gauss Elimination code

Ax=b

for

A

plot of

log(d)

on the

2500×2500

). - When solving for

(0

of rardom numbers, where the user can input the block size, d. The function should also output a right-hand-side vector

b

What are the techniques used for class imbalance problem. Give specific techniques used in literatüre and explain each of them.

Questions 515

i

inner blacks, each of width

. The elements in the

d×d

). function called BiockD a agonalsolver, and the supplied Gauss Elimination code

Cz

for

d=[5,10,15,⋯,50]

plot of

log(t)

on the

x

). - When solving for

d=[5,10,15,⋯,50]

b

of random numbers, and thus generates a complete block-diagonal system of linear equations

HI,…→

, Welcome to the Guessing Number Game Enter a number between 1 and 100 , or 0 to quit: 90 Too low, try again Enter a number between 1 and 100, or 0 to quit: 91 Too low, try again Enter a number between 1 and 100 , or 0 to quit: 92 Too low, try again Enter a number between 1 and 100 , or

Questions 518

Exercise 2 Consider the incomplete C program simpledb.c shown in Figure

(00−59):")

; printf("\nEnter the measurement value as a real number:"); Figure 3

b. A write of nine continuous blocks of data

Questions 520

is even. Perform the following operation

N/2

will be added to the current score. Strings inside () denote the binary representation. Note: The Bitwise AND operator (\&) compares each bit of the first operand to the corresponding bit of the second operand. If both bits are 1 , the corresponding result bit is set to 1. Otherwise, the corresponding result bit is set to 0 . Note: Go is the preferred programming language for this question. Task Determine the maximum possible score. Example Assumptions -

N=4

and then pair

(4,1)

and then pair

(3,1)

and then pair

(3,4)

integers Input format Note: This is the input format that you must use to provide custom input (available above the Compile and Test button). - The first line contains a single integer

N

5

,N

N=4

- nums

(3,4)

. The resulting Bitwise AND is 1 , which has the most significant bit of 1 . So you add 1 to the score. The maximum value of the score is

i

with element

For this program, adjust the values by dividing all values by the largest value. The input begins with an integer indicating the number of floating-point values that follow.

Output each floating-point value with two digits after the decimal point, which can be achieved by executing

Problem 1. [35 points] An incomplete C program is given to find the parameters of a circle given by

C:(x−x

+(y−y

c

c

2

c

are the

x

is the radius of the circle. For this purpose, you need to read three distinct points on the circle from the user into a user defined data type that can hold two coordinates of a point from STDIN. See the sample runs below. (a) [10 points] Use the defined data type that can hold two coordinates of a point

p

and

x

- and

C

function to find center coordinates of the circle passing through the three Points as inputs. Given points

2

on the circle; the perpendicular bisectors of two chords meet at the centre. Hence, the

x

c

−m

12

∗m

−y

∗(x

)−m

+x

,

y

12

1

+

+y

2

m

12

are the slope of the lines passing through the points

2

,p

3

and

m

12

−x

−y

C

function to find radius of the circle using a single point on the circle and the center coordinates of the circle. (d)

x

and

y

coordinates for a point:

y

coordinates for a point:

y

center is

2+(y−1.77)

***PLEASE DONT COPY FROM ANOTHOR ANSWER ON CHEGG***

Suppose that a disk drive has 5,000 cylinders, numbered 0 to 4,999. The drive is currently serving a request at cylinder 2,150, and the previous request was at cylinder 1,805. The queue of pending requests, in FIFO order, is:

SCAN

LOOK

1,2,3,…

. up to a user specified number of mailboxes

Questions 527

A projectile equation where the velocity is 60 m/s at an angle 50 degrees from a height of 3 meters.

QUESTION [40 MARKS]

In assignment 1, we discussed in general the techniques of software integration. So, for this assessment, the student needs to find TWO (2) case studies and do research on techniques used for integration strategy for their organization. The report content must be discussed the organization’s background before and after the integration strategy is done.

Discussion on the technique used for Case Study 1 (10 marks)

Discussion on the technique used for Case Study 2 (10 marks)

program is given to display the count of characters, words and lines present in a file. Such a program is used to find out number of lines, word count, characters count in the files specified in the command-line arguments. Here is the expected behavior of this program. - By default it should displays four-columnar output for a given input file. - First column shows number of lines present in a file specified, [5 points] - Second column shows number of words present in the file, [7 points] - Third column shows number of characters present in file [5 points] - Fourth column itself is the file name which should be given as input argument thought the command-line. - If no file is specified it should state as such. [ 3 points] - Your code should work with as many files as inside a given folder. [5 points] Remark: In order to count lines, consider the corresponding white space character. In order to count words, count the transitions from non-white space to white space characters. The ctype.h header file may be useful which is defined under the C Standard Library that declares several functions that are useful for testing and mapping characters. Inside the folder qe 2 , you may find five input text files to test your program. Your code should work with as many files as inside a given folder, i.e., your code will be tested against other inputs. Note that

q

2

qe

2/

qe

2/∗

inout 4 .txt

Questions 530

and Company

Y

and Company

Y

?

Questions 532

Bob is working on AWS. While working on an application, he has a set of EC2 instances and is on-premises. He wants to automate the deployment of the application using the Code Deploy tool. Help him to find which of the following step is not required. Ensure both Instances and On-premises servers have the Code Deploy agent installed. Ensure both EC2 Instances and On-premises servers can connect to the Code Deploy service. Ensure both EC2 Instances and On-premises servers are tagged. Ensure both EC2 Instances and On-premises servers have instance profiles attached to them. Reset Answer

Questions 534

, the message should be: "Move up" direction = 2 , the meisage should be: "Move right" drection

=3

which represents how many moves to perform (naximum vald value of

n

) Move left counger (idirection m 4) American University in Cairo Computer Science \& Engineering Department CSCE 1001 (Dr. Mikhail) Fall 2022 Assieriment is: Due: Friday 25 " Noveinher 2022 (Maldight] - Cul the Guncoon move senitis to if the number returned from caline the function ermintengien to dispirr a metaet. - At the eca or the proeram dispay the 4 courters to show cieariy to the uger how many moves in each direction Sample Output: American University in Cairo Computer Science \& Engineering Department csct 1001 (De. Mikhail) Fall 2022

Questions 535

D

2

D

4

128.96.39.20

(b)

128.96.40.148

(e)

Only C++

Can you add some adjustments to fix the mistake of the code below:

The code:

#include <iostream>

using namespace std;

//Profile class.

char charName[50];

char charGender;

float floatBMI = 0;

float floatCalories = 0;

{

//Here opening a file in append mode.

cin >> intProfile_ID;

// added check for profile id.

}

cout << "Enter Name: ";

cout << "Enter Gender (F : Female or M: Male ): ";

cin >> charGender;

myProfile << "\n" << intProfile_ID << " , " << charName << " , " << strDate << " , " << charGender << " , " << intWeight << " , " << floatHeight << endl;

myProfile.close();

{

this->floatBMI = BMI;

this->floatCalories = Calories;

}

cout << "Profile ID: " << intProfile_ID << endl;

cout << "Name: " << charName << endl;

cout << "BMI: " << floatBMI << endl;

cout << "Calories: " << floatCalories << endl;

{

int n;

int loop = 0;

Profile prof[30];

cout << "Enter your choice: ";

//Taking users input.

//Adding the profile.

case 1:

prof[i].getData(i);

}

cout << "Enter your profile ID: ";

cin >> profile;

//bmi calculation formula.

bmi = (prof[i].intWeight) / ((prof[i].floatHeight) * (prof[i].floatHeight));

ofstream myProfile;

myProfile.open("profile.txt", ofstream::app);

}

}

cout << "Enter your profile ID: ";

cin >> profile1;

//Calculating the calories and then set it with the profile respectively.

calories = (66.47 + (13.75 * prof[i].intWeight) + (5.003 * ((prof[i].floatHeight) * 100)));

ofstream myProfile;

myProfile.open("profile.txt", ofstream::app);

}

}

cout << "Enter your profile name: ";

cin >> name;

//Searching for the name in profile, if found then display its contents.

if (result == 0)

}

break;

default:

loop = 1;

Questions 537

1. By computer, plot graphs of

for

p=0,1,2,3

0

N

p

, and

x

Questions 538

6. (14 points) The following table is a routing table using CIDR. Address bytes are in hexadecimal. State to what next hop the following will be delivered. (a) C4.5E.1A.87 (b) C4.5E.32.09 (c) C4.69.22.89 (d)

Questions 539

Solve these recurrence relations together with the initial conditions given. a)

n−1

=3

b)

n−1

=2

c)

n−1

n≥2,a

0

=0

d)

n−1

n≥2,a

0

=8

e)

n−1

n≥2,a

0

=1

f)

n−2

=0,a

1

Questions 541

An if statement does not need to have an else if or else needs to have an else if and an else needs to have an else but not an else if needs to have an else if but not an else

Supports data entry as well as report generation

Uses the following class throughout the application:

Class #1: Patient

Attributes

a−b

and the link b-a both have weight 10.) Put arrows on the edges to show the shortest path from every node to the destination node d. That is, show the "sink tree" leading to node

Questions 545

4. From the graphs in Problem 3, read approximate values of the first three zeros of each of the functions, and then find more accurate values by computer. 5. By computer, plot

(x)

. Do you recognize the curve? See Problem

12.9

and note that the spacing between consecutive zeros is tending to

π

(int

k){

The above code can be written: if

(k>5&&k!=5)

return true; else return false; while

(k!=5)

return false;

Questions 547

. What is the Balance Due for the invoice? Note: Answer this question in the table shown below. Round your answer to the nearest dollar amount. n. Select Save and leave the Invoice displayed 3. View the Transaction Journal for the Invoice. a. From the bottom of the Invoice, select More

>

false;

}

This exercise is designed to build your skills in breaking a program down into modular components through the use of Methods. For this exercise, we will develop a program that lets the user play the game of Rock-Paper-Scissors against the computer. Post your source code to canvas. Game Overview (Source: Wikipedia) Rock-paper-scissors is a hand game usually played between two people, in which each player simultaneously forms one of three shapes with an outstretched hand. These shapes are "rock" (O a simple fist), "paper" (B a flat hand), and "scissors" (

У

U.S. bushel - To convert from miles to kilometers use the following formula: 1 mile

=1.60934 km

You are viewing 1/3rd of the document.Purchase the document to get full access instantly

Immediately available after payment
Both online and downloadable
No strings attached
How It Works
Login account
Login Your Account
Place in cart
Add to Cart
send in the money
Make payment
Document download
Download File
img

Uploaded by : Therese Cormack

PageId: DOC08DF83D