Questions
Subtract in binary

Subtract in binary

In: Computer Science

Add in Octal

Add in Octal

In: Computer Science

I need the following problem to be coded in python without using Numpy: Given input features...

I need the following problem to be coded in python without using Numpy:

Given input features x1​, x2​,..., xi​ and corresponding weights w0​, w1​, w2​,...wi​. Write a function, called 'Perceptron', that returns the output value yi. For your function, use the following perceptron activation function:

g(X,W)={1 if wTx>0;0 otherwise}

The inputs X and W will be arrays of the input feature and weight values, respectively. All values will be integers. Your function will return gp​(X,W), which is a single integer value:

def perceptron(X, W):

In: Computer Science

Subtract in Hexadecimal

Subtract in Hexadecimal

In: Computer Science

Which one of these code fragments could possibly be a comment that could be used to...

Which one of these code fragments could possibly be a comment that could be used to perform a XSS injection?

Select one:

a. <script>Evil()</script>

b. DROP TABLE users;

c. admin’ OR 1=1 --

In: Computer Science

Java Script. Develop a program that will determine the slugging percentages and batting average of several...

Java Script.

Develop a program that will determine the slugging percentages and batting average of several New York Yankees from the 2006 season. Slugging percentage is calculated by dividing the total number of bases by the number of at bats. The number of bases would be one for every single, two for every double, three for every triple, and four for every home run. The batting average is calculated by dividing the total number of hits by the number of at bats. You do not know the number of players in advance, but for each player you know their number of singles, doubles, triples, home runs, total number of at bats, and the player's name (use the proper type and method for each variable).

You will use a while sentinel loop on the 1st item to input. If it is not the sentinel, go into the while sentinel loop and separately input the rest of the input items (be careful of the enter in the input memory buffer for the player name). You will then calculate the total bases and the slugging percentage. You will then calculate the batting average. You will then print out the player's name, the labeled slugging percentage for that player to three decimal places, and the labeled batting average for that player to three decimal places. Use separate output statements. Print a blank line between players. This loop will repeat for as many players as you need.

Run your program with the following players and sentinel value (to show the sentinel value worked):

Create a java script. Modify your program that determined the slugging percentages and batting average of several New York Yankees from the 2006 season. The user now knows in advance the number of players to process. You will ask the user to input the number of players and input that value into a variable. You will use a while loop to check their input. While their input is less than zero or more than twenty, you will ask them to re-input the number of players, since the number of players has to be from zero to twenty. Use proper form for the while loop. Since we now know the number of players, use a for loop to count up to their number. Inside the loop, input all the data, calculate the batting average and slugging percentages, and print the name, batting average, and slugging percentage as in the while sentinel loop. Use proper form for the for loop. Make sure everything from part one is working properly. Slugging percentage is calculated by dividing the total number of bases by the number of at bats. The number of bases would be one for every single, two for every double, three for every triple, and four for every home run. The batting average is calculated by dividing the total number of hits by the number of at bats. You do not know the number of players in advance, but for each player you know their number of singles, doubles, triples, home runs, total number of at bats, and the player's name (use the proper type and method for each variable). Then use a for loop with a counter. While the counter is less than or equal to the number of players, go into the for loop and separately input the items (be careful of the enter in the input memory buffer for the player name). You will then calculate the total bases and the slugging percentage. You will then calculate the batting average. You will then print out the player's name, the labeled slugging percentage for that player to three decimal places, and the labeled batting average for that player to three decimal places. Use separate output statements. Print a blank line between players. This loop will repeat for as many players as the user asked for. Run your program with the following input and players: Enter number of players (0 – 20): 25 Invalid number of players. Enter number of players (0 – 20): -1 Invalid number of players. Enter number of players (0 – 20): 3 Singles: 158 Doubles: 39 Triples: 3 Home Runs: 14 At Bats: 623 Player: Derek Jeter Singles: 51 Doubles: 25 Triples: 0 Home Runs: 37 At Bats: 446 Player: Jason Giambi Singles: 104 Doubles: 26 Triples: 1 Home Runs: 35 At Bats: 572 Player: Alex Rodriguez

In: Computer Science

Assignment Questions: 1. Write a short note on external fragmentation. 2. Why we need operating system....

Assignment Questions:
1. Write a short note on external fragmentation.
2. Why we need operating system. If we don’t have operating system what would be the consequences?
3. What is BIOS?
4. Explain resources.
5. What is program counter?

In: Computer Science

Wana Decryptor Attack Case Study - Part 1 Scenario: You are employed at a bank of...

Wana Decryptor Attack Case Study - Part 1

Scenario:

You are employed at a bank of medium size, worth 5 billion dollars. The IT Director reports to the CIO – both the CIO and CISO report to the COO. At 11:00 A.M. on a Monday morning, the IT Help Desk receives a call from a user in the Wire Transfer Department. He reports that his computer is frozen, and appears to have a message that some type of ransom is requested to free the files up from a type of encryption.

What should your help desk do next? Consider the following:

  • What is your response plan to this incident?
  • How would you escalate this situation?
  • Who would you notify?
  • What is your customer notification plan?
  • What is the relevant regulatory requirement?

Let’s identify the most probable sequence of events. Select One:

  1. The Help Desk opens a ticket, assigns it to a technician to respond to the user’s workstation, to inspect and determine what the actual problem is and whether it is a virus or a computer issue that could be resolved by the IT team.
  2. The Help Desk instructs the user to unplug his computer from the network, proceeds to open a ticket and assigns an IT tech to inspect the user’s computer for an analysis and a possible solution.
  3. The Help Desk simultaneously proceeds to notify the IT Director of the issue, dispatches a technician and awaits feedback.
  4. In addition to #3, the Help Desk proceeds to inform the CISO of the occurrence.
  5. The Help Desk instructs the user to shut down and restart his computer to see if the problem has been remedied before taking any action.
  6. Any other actions that are not listed above?

As you reflect on what to do and what may happen, the IT Technician arrives:

  • The technician immediately determined and reported that the computer was infected with Ransomware.
  • He states that there is no way to remove the malware other than disconnecting it from the network and re-imagine it.
  • The other option is to pay the ransom of $300.00.

What now? Post your primary thoughts on the scenario, considerations on the most probable next steps, and what you would do after learning the new information from the IT technician's report then find commonalities and differences in your thoughts and approaches and discuss as a class.

In: Computer Science

java program public class FavoriteList { protected PositionList> fList; // List of entries /** Constructor; O(1)...

java program

public class FavoriteList {

protected PositionList> fList; // List of entries

/** Constructor; O(1) time */

public FavoriteList() { fList = new NodePositionList>(); }

// Complete your work and write out a main function to test

top, access and remove methods.

}

In: Computer Science

Radio Link Loss Radio link loss is a key factor in the design of any radio...

Radio Link Loss

Radio link loss is a key factor in the design of any radio communications system or wireless communication system.

The radio link loss is a signal loss that essentially reduces the power density of an electromagnetic wave or signal. Since the signal propagates through the environment in which it is traveling., All radio communication, broadcast, and wireless communication systems are affected by this.

Different reasons for the radio link loss

1. Free space loss:  Free space loss occurs when the signal travels through space without any other effects attenuating the signal. It will still diminish as it spreads out. As the signal has to cover a wider area, conservation of energy tells us that the energy in any given area will reduce as the area covered becomes larger.

2. Diffraction:  Radio link loss occurs when an object/obstacle appears in the path. The signal can diffract around the object, but losses occur. The loss is higher, the more rounded the object.

  1. Multipath:  In a real terrestrial environment, signals will be reflected, and they will reach the receiver via several different links/paths. These signals may add or subtract from each other depending upon the relative phases of the signals. If the receiver is moved, the scenario will change, and the overall received signal will be found to vary with position.

4. Absorption losses:  Absorption losses occur if the radio links pass into a medium that is not transparent to radio signals.

For, e.g., Buildings, walls, etc., Atmospheric moisture, i.e., moisture in the air, Vegetation, i.e., in dense forest trees and foliage, can attenuate radio signals, particularly when wet.

  1. Terrain (land):  The terrain over which signals travel will significantly affect the signal. Hills which obstruct the path will considerably attenuate the signal, often making reception impossible
  2. Atmosphere:  The atmosphere can affect radio links paths.

How can we reduce loss?

  1. Radio link loss cab is reduced by Predicting radio link loss.

2. Understanding the various elements affecting radio link loss is to be able to predict the loss for a given link.

  Most radio link loss predictions are made using the following techniques.

· Statistical methods:  Statistical methods of predicting signal path loss rely on measured and averaged losses for typical types of radio links. The figures are entered into the prediction model, which can calculate the figures based on the data. This type of approach is normally used for planning cellular networks, broadcast networks.

· Deterministic approach:  This approach to radio link loss and coverage prediction to be used for short-range links where the amount of required data falls within acceptable limits.

Radio Link Loss

Radio link loss is a key factor in the design of any radio communications system or wireless communication system.

The radio link loss is a signal loss that essentially reduces the power density of an electromagnetic wave or signal. Since the signal propagates through the environment in which it is traveling., All radio communication, broadcast, and wireless communication systems are affected by this.

Different reasons for the radio link loss

1. Free space loss:  Free space loss occurs when the signal travels through space without any other effects attenuating the signal. It will still diminish as it spreads out. As the signal has to cover a wider area, conservation of energy tells us that the energy in any given area will reduce as the area covered becomes larger.

2. Diffraction:  Radio link loss occurs when an object/obstacle appears in the path. The signal can diffract around the object, but losses occur. The loss is higher, the more rounded the object.

  1. Multipath:  In a real terrestrial environment, signals will be reflected, and they will reach the receiver via several different links/paths. These signals may add or subtract from each other depending upon the relative phases of the signals. If the receiver is moved, the scenario will change, and the overall received signal will be found to vary with position.

4. Absorption losses:  Absorption losses occur if the radio links pass into a medium that is not transparent to radio signals.

For, e.g., Buildings, walls, etc., Atmospheric moisture, i.e., moisture in the air, Vegetation, i.e., in dense forest trees and foliage, can attenuate radio signals, particularly when wet.

  1. Terrain (land):  The terrain over which signals travel will significantly affect the signal. Hills which obstruct the path will considerably attenuate the signal, often making reception impossible
  2. Atmosphere:  The atmosphere can affect radio links paths.

How can we reduce loss?

  1. Radio link loss cab is reduced by Predicting radio link loss.

2. Understanding the various elements affecting radio link loss is to be able to predict the loss for a given link.

  Most radio link loss predictions are made using the following techniques.

· Statistical methods:  Statistical methods of predicting signal path loss rely on measured and averaged losses for typical types of radio links. The figures are entered into the prediction model, which can calculate the figures based on the data. This type of approach is normally used for planning cellular networks, broadcast networks.

· Deterministic approach:  This approach to radio link loss and coverage prediction to be used for short-range links where the amount of required data falls within acceptable limits.

Please rewrite it in your own words (I mean paraphrase)

In: Computer Science

Critical Thinking 6-4: Network Firewall Comparison Use the Internet to identify three network firewalls, and create...

Critical Thinking 6-4: Network Firewall Comparison

Use the Internet to identify three network firewalls, and create a chart that compares their features. Note if they are rule-based or application-aware, perform stateless or stateful packet filtering, what additional features they include (IDS, content filtering, etc.), their costs, etc. Which would you recommend? Why?

In: Computer Science

Give a greedy algorithm to make a reasonable attempt at coloring a graph in ?(? +...

Give a greedy algorithm to make a reasonable attempt at coloring a graph in ?(? + ?) time. In pseudo code

In: Computer Science

Suppose a linked list of 20 nodes. The middle node has a data –250. Write the...

Suppose a linked list of 20 nodes. The middle node has a data –250. Write the pseudocode to replace the middle node of the linked list with a new node and new data. Assume that the list's head pointer is called head_ptr and the data for the new node is called entry

In: Computer Science

In C programming, Thanks Write a program to determine which numbers in an array are inside...

In C programming, Thanks

Write a program to determine which numbers in an array are inside a particular range. The limits of the range are inclusive.

You have to write a complete "C" Program that compiles and runs in Codeblocks. (main.c)

1. Declare an array that can contain 5 integer numbers. Use as the name of the array your LastName.

2. Use a for loop to ask the user for numbers and fill up the array using those numbers.

3. Ask the user for the lower limit of the range.

4. Ask the user for the upper limit of the range.

5. Use a for loop to check all the numbers in the array and print the numbers inside the range.

The following is an example of how your program should look when you execute it:

Enter a number to store in the array: 10
Enter a number to store in the array: 90
Enter a number to store in the array: 145
Enter a number to store in the array: 94
Enter a number to store in the array: 97

Enter the lower limit of the range: 90
Enter the upper limit of the range: 99

The numbers in the range are: 90, 94, 97

In: Computer Science

how to count the word of occurance in the text file example input text file :...

how to count the word of occurance in the text file

example input text file : "test1.txt
hello : 1
good : 1
morning: 1
how : 1
are : 2
you : 2
good : 1

example output text file : "test2.txt"
1 : 4
2 : 2
3 : 0
4 : 0
5 : 0

In: Computer Science