Questions
Given the strings s1 and s2 that are of the same length, create a new string...

Given the strings s1 and s2 that are of the same length, create a new string s3 consisting of the last character of s1 followed by the last character of s2, followed by the second to last character of s1, followed by the second to last character of s2, and so on

In: Computer Science

2. Convert the following decimal fractions to binary with a maximum of six places to the...

2. Convert the following decimal fractions to binary with a maximum of six places to the right of the binary point: [12]

a. 25.84375 b. 57.55 c. 80.90625 d. 84.874023

In: Computer Science

In Java In mathematics, factorial of a non-negative integer n, denoted by n! , is the...

In Java

In mathematics, factorial of a non-negative integer n, denoted by n! , is the product of all positive integers less than or equal to n. For example,

5! = 5 * 4 * 3 * 2* 1 = 120

3! = 3 * 2 * 1 = 6

2! = 2 * 1 = 2

The value of 0! is 1.

Write a program that asks user to enter an integer > 0; if a valid value is entered, it should calculate and display factorial of the number entered. If the user enters an integer <=0, display a message "Invalid entry - valid entry is an integer > 0" and have them re-enter the information.

In: Computer Science

Use Python to solve, show all code Write a program that sums a sequence of integers...

Use Python to solve, show all code

Write a program that sums a sequence of integers from a starting integer to and ending integer. The sequence is generated by skipping a value (e.g. 1,3,5,… or 2,6,10,14…). Prompt the user for a) a starting value greater than 0. Validate the value is greater than 0.

b) the ending value.

c) the value to skip

Print out the sum of the numbers for the sequence. If the starting value is 2, the ending value is 10 and the value to skip is 2, the sequence would be 2,4,6,8,10

Sample Interaction:

Enter the starting value: -1

Error – invalid number

Enter the starting value: 2

Enter the ending value: 10

Enter the value to skip: 2

The sum of the integers from 2 to 10 skipping 2 is 30

In: Computer Science

For this Discussion, you will analyze mobile security threats and evaluate countermeasures. Briefly describe your mobile...

For this Discussion, you will analyze mobile security threats and evaluate countermeasures.

Briefly describe your mobile device and another device currently on the market that uses a different OS. Explain the security vulnerabilities associated with each device. Explain the security solutions that would address the vulnerabilities. Finally, state which OS has more robust security and explain your reasoning.

In: Computer Science

Create a webpage with Margins, Padding, Alignment, and Floating: Begin with a basic web page using...

Create a webpage with Margins, Padding, Alignment, and Floating:

  1. Begin with a basic web page using the 5 required html tags.
  2. Add 4 or 5 paragraphs of text from a page in this chapter.
  3. Format the text to appear as on the page using < p>, < h1>, < ol> and < li> tags.
  4. Enclose the content with a < div> tag.
  5. With an internal stylesheet, set the body element to have no margins and a gray background.
  6. Style the div element with a width of 400 pixels, no top and bottom margins, automatic left and right margins, 10 pixels of padding all around, a 1 pixel black border and a white background.
  7. You finish page should look like this: (https://s3.amazonaws.com/blackboard.learn.xythos.prod/58771c61a39f4/3132468?response-cache-control=private%2C%20max-age%3D21600&response-content-disposition=inline%3B%20filename%2A%3DUTF-8%27%27Screen%2520Shot%25202020-10-08%2520at%25205.09.17%2520PM.png&response-content-type=image%2Fpng&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20201009T150000Z&X-Amz-SignedHeaders=host&X-Amz-Expires=21600&X-Amz-Credential=AKIAYDKQORRYTKBSBE4S%2F20201009%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=663f55cb392c78ef4fc1c5827d8925574c7fe821c186ba18165606c3f2e43814) but choose something else!

In: Computer Science

Using the module discussion forum, work with your fellow students to identify any other database benefits...

Using the module discussion forum, work with your fellow students to identify any other database benefits you can think of, as say compared to a spreadsheet or basic file storage.

In: Computer Science

MACs Question 3: 3a.) Why should a MAC be configurable? 3b.) What are the effects of...

MACs

Question 3:

3a.) Why should a MAC be configurable?
3b.) What are the effects of RF radio realities on the MAC layer?

In: Computer Science

In Java A palindrome is a word or sequence of characters which reads the same backward...

In Java

A palindrome is a word or sequence of characters which reads the same backward and forward, such as madam, dad, racecar, 5885. In java Write a program that asks user to enter a word and prints if the word is a palindrome or not.

In: Computer Science

in Python, Define the class called Line which represents a line with equation ?=??+? with input...

in Python,

Define the class called Line which represents a line with equation ?=??+? with input slope ? and intercept ? to initialize the instances. It should include:

attributes named ? and ? to represent slope and intercept.
method named intersect to return the list, containing coordinates of the intersection point of two lines.
support for + operator to compute the addition of two equations. The sum of two Line objects ?=?1?+?1 and ?=?2?+?2 is defined as the line ?=(?1+?2)?+?1+?2 .
printable representation for the equation of line, which we have already defined in __repr__ speical method below.

In: Computer Science

Wireless Sensor Networks/Internet of Things What should be the major components of an energy consumption model...

Wireless Sensor Networks/Internet of Things

What should be the major components of an energy consumption model for a sensor node?

In: Computer Science

How would you implement smart/low cost flooding in a WSN? How would you know if nodes...

How would you implement smart/low cost flooding in a WSN? How would you know if nodes received the messages?

In: Computer Science

Extract an 8 × 8 patch from the image. To access to the (i, j)th pixel...

Extract an 8 × 8 patch from the image. To access to the (i, j)th pixel of the image, you can type Y(i,j). To access the an 8×8 patch at pixel (i, j), you can do Y(i:i+7, j:j+7) for some index i and j. Extract all the available 8 × 8 patches from the image, and store them as a 64 × K matrix where K is the number of patches. The following code will be useful.

for i=1:M-8

for j=1:N-8

z = Y(i+[0:7], j+[0:7]);

... % other steps; your job.

end

end

Here, M and N are the number of rows and columns of the image, respectively. No need to worry about the boundary pixels; just drop them.

Hint: Use the command reshape in MATLAB (and Python) to turn an 8 × 8 patch into a 64 × 1 column vector. Submit the first 2 columns and the last 2 columns of your data matrix.

In: Computer Science

Wireless Sensor Networks/Internet of Things Considering sensors and signal processing (based on in-class materials or your...

Wireless Sensor Networks/Internet of Things

Considering sensors and signal processing (based on in-class materials or your own knowledge if you have a background here) how would you determine if the entity in your sensor field was an elephant or a lion

In: Computer Science

Wireless Sensor Networks/Internet of Things Topic Quesiton 8 In wireless network snooping is possible. What are...

Wireless Sensor Networks/Internet of Things Topic

Quesiton 8

In wireless network snooping is possible. What are the positive aspects of snooping?

In: Computer Science