Questions
Complete this in simple python code. Sepia Tone images are those brownish colored images that may...

Complete this in simple python code.
Sepia Tone images are those brownish colored images that may remind you of times past. The formula for creating a sepia tone is as follows:::
.............................................................................
newR = (R × 0.393 + G × 0.769 + B × 0.189)
newG = (R × 0.349 + G × 0.686 + B × 0.168)
newB = (R × 0.272 + G × 0.534 + B × 0.131)
.............................................................................
Write a function to convert an image to sepia tone. Remember that rgb values must be integers between 0 and 255...

In: Computer Science

When browsing to a web page you’ve configured, you are receiving a 403 error. What are...

When browsing to a web page you’ve configured, you are receiving a 403 error. What are two possible causes, and how would they be remedied?

how to solve 403 error issue?

In: Computer Science

The two standard ACL commands are getfacl and setfacl. 1. What is the difference between them?...

The two standard ACL commands are getfacl and setfacl.

1. What is the difference between them?

2. How can setfacl help achieve security hardening?

In: Computer Science

For the following exercises, enter the data from each table into MS-Excel and graph the resulting...

For the following exercises, enter the data from each table into MS-Excel and graph the resulting scatter plots (Use a smoothing function). Determine whether the data from the table could represent a function that is linear, exponential, or logarithmic.

n

1.25

2.25

3.56

4.2

5.65

6.75

7.25

8.6

9.25

10.5

f (n)

5.75

8.75

12.68

14.6

18.95

22.25

23.75

27.8

29.75

33.5

x

1

2

3

4

5

6

7

8

9

10

f (x)

2

4.079

5.296

6.159

6.828

7.375

7.838

8.238

8.592

8.908

m 0

1

2 3 4 5 6 7 8 10
F(m) 10 12 14 16 18 20 22 24 26

28

y

1

2

3

4

5

6

7

8

9

10

f (y)

2.4

2.88

3.456

4.147

4.977

5.972

7.166

8.6

10.32

12.383

z

4

5

6

7

8

9

10

11

12

13

f (z)

9.429

9.972

10.415

10.79

11.115

11.401

11.657

11.889

12.101

12.295

In: Computer Science

Create this C++ program using classes 1. Create a file text file with a string on...

Create this C++ program using classes

1. Create a file text file with a string on it

2. Check the frecuency of every letter, number and symbol (including caps)

3. Use heapsort to sort the frecuencys found

4. Use huffman code on the letters, symbols or numbers that have frecuencys

I created the file, and the frecuency part but i'm having trouble with the huffman and heapsort implementation.

In: Computer Science

Php 2. Use case diagram and the purpose of using a use case diagram.==> analysis 3....

Php

2. Use case diagram and the purpose of using a use case diagram.==> analysis

3. use case diagram and data flow diagram==> model the logical concept

4. draw a use case diagram or describe/explain a use case diagram

5. data flow diagram: context diagram + a set of subdiagrams

In: Computer Science

Question: Write a single SQL query that, for each pair of actors, lists their two actor_ids...

Question: Write a single SQL query that, for each pair of actors, lists their two actor_ids
and the number of films in which both actors appeared.

DATABASE SCHEMA

CREATE TABLE actor (
actor_id INTEGER,
first_name TEXT,
last_name TEXT);


CREATE TABLE film (
film_id INTEGER,
title TEXT,
description TEXT,
length INTEGER);


CREATE TABLE film_actor (
actor_id INTEGER,
film_id INTEGER);

In: Computer Science

There is a famous puzzle called the Tower of Hanoi. Code the recursive implementation of it...

There is a famous puzzle called the Tower of Hanoi. Code the recursive implementation of it with Python.

In: Computer Science

Language Javascript Implement Insertion Sort 1. Non-increasing order, 2. At least an array of 10 elements.,...

Language Javascript

  1. Implement Insertion Sort

    1. Non-increasing order,

    2. At least an array of 10 elements.,

    3. You can use a static array.

In: Computer Science

Describe the A* algorithm. Give one search example: give one graph as example with a heuristic...

Describe the A* algorithm. Give one search example: give one graph as example with a heuristic function for each node; give the start node and goal node; apply the A* algorithm on this problem. Show the steps and sequence of nodes visited in order that leads to the optimal solution.

In: Computer Science

Write a program that translates an English word into a Pig Latin word. Input ONE, and...

Write a program that translates an English word into a Pig Latin word. Input ONE, and ONLY one, word from the user, and then output its translation to Pig Latin.

The rules for converting a word to Pig Latin follow.

  1. The general form for converting a word is to remove the first letter. Then append to the end of the word a hyphen, followed by the first letter that was removed, followed by "ay". For example, "robot" becomes "obot-ray" and "Hello" becomes "ello-Hay".
  2. If the word begins with a vowel (an element of "aeiouAEIOU") simply append "-way". For example, "example" becomes "example-way" and "All" becomes "All-way".
  3. If the word begins with "th" (or "Th", "tH", or "TH"), remove the prefix and append "-thay" (or "-Thay", "-tHay", or "-THay") to the word. For example, "this" becomes "is-thay" and "The" becomes "e-Thay".

Use at least the REQUIRED METHODS listed below, with the exact same SPELLING for method names and parameters.

Input Specification

Input ONE English word as a string. If multiple words are entered ignore any beyond the first.

Use PRECISELY the format below with the EXACT same SPACING and SPELLING.

Please enter a word ==> 

Output Specification

Output an introductory message, a prompt for the English word, and a translation for the inputted word.

Use PRECISELY the format below with the EXACT same SPACING and SPELLING. The output below assumes the user entered "Hunger".

This program will convert an English word into Pig Latin.

Please enter a word ==> Hunger

"Hunger"
  in Pig Latin is
"unger-Hay"

Required Methods

// Prompt and read a word to translate
public static String  readWord (Scanner console)

// Convert a word to Pig Latin and return it
public static String  convertWord (String englishWord)

// Return true if "c" is a vowel, false otherwise.
// Handle both lowercase and uppercase letters.
public static boolean isVowel (char c)

// Print result of translation
public static void printResult (String englishWord, String pigLatinWord)

Hints

BEFORE you start coding, think about which methods each method will call. Which methods should "main" call? Create a diagram which shows the calling relationships.

There are many useful String methods listed HERE. You may find startsWith and charAt helpful.

Style

Write comments

  • Choose mnemonic, meaningful variable names (e.g. balance, interestRate)
  • Indent consistently (Ctrl+Shift+F will format your code)
  • Remember the comment block at the top of your program

In: Computer Science

Write a C++ script to perform the following: a.) Ask a user to enter 2 real...

Write a C++ script to perform the following:

a.) Ask a user to enter 2 real numbers.
b.) Save the user response as a variable a and b.
c.) Display if the numbers are even or odd.
d.) Check if the number a belongs in the interval D = [10, 99], display the output as "a is between 10 and 99" or "a is not between 10 and 99".
e.) Check if the number b belongs in the interval E = [0, 50], display the output as "b is between 0 and 50" or "b is not between 0 and 50".

In: Computer Science

Digital Forensics, At least 200 words for each question 1/ Research a network attack (DDoS, Man-in-the-Middle,...

Digital Forensics, At least 200 words for each question

1/ Research a network attack (DDoS, Man-in-the-Middle, IP Spoofing, etc.) and explain it in further detail.

2/ Discuss ways that forensic examiners have been able to identify and analyze these attacks.

3/ Find an attack , where an examiner was able to successfully identify the attacker, and explain techniques used to do so.

In: Computer Science

I want to calculate the max, min, mean, standard deviation and the percentage of data within...

I want to calculate the max, min, mean, standard deviation and the percentage of data within one standard deviation from a file already existing in my directory using JAVA. As you can see it below, I have found max, min, mean and stand deviation. How can I get the percentages of data within one standard deviation in the following code?

import java.io.*;
import java.util.Scanner;

public class DataFile {

public static void main(String[] args) {
    // declare variables
    double number, maximum, minimum, sum, mean, standardDeviation;
    int count;

    Scanner file = null;

/* -------------------------------------------------------------------------- */
    try {
        file = new Scanner(new File("RawData.txt"));
    }

    catch(FileNotFoundException e) {
        System.out.print("Error; The program was terminated!");
        System.exit(1);
    }

/* -------------------------------------------------------------------------- */
    // initialize variables
    maximum = file.nextDouble();
    minimum = maximum;
    sum = 0;
    count = 1;

    while(file.hasNextDouble()) {
        number = file.nextDouble();

        if(number > maximum)
            maximum = number;

        else if(number < minimum)
            minimum = number;

        sum += number;
        count += 1;

    } // end while loop

    file.close();

/* -------------------------------------------------------------------------- */
    // mean calculation
    mean = sum / count;

    // standard deviation calculation
    
double stdDevSum = 0;
double stdDevMean = 0;
double stdDev = 0;

double sumOfSquares = squareSum - ((Math.pow(computationalSum, 2)/(count-1)));
double sSquared = sumOfSquares/(count-1);
double otherStdDev = Math.sqrt(sSquared);

// display statistics
System.out.println("Maximum ------------> " + maximum                   );
System.out.println("Minimum ------------> " + minimum                   );
System.out.println("Sum ----------------> " + sum                       );
System.out.println("Count --------------> " + count                     );
System.out.println("Mean ---------------> " + mean                      );
System.out.println("StdDev -------------> " + otherStdDev);

    

} // end method main

} // end class DataFile

In: Computer Science

I would like to see a PowerShell script(for purely inspirational work to use as an inspiration...

I would like to see a PowerShell script(for purely inspirational work to use as an inspiration for helping to develop my skills as a hobby.

*** This should all be done in a loop **

Before beginning, You will need a simple text file with three weeks of scores between Michigan and Michigan State. Example:

UM21, MSU 14

UM28, MSU 35,

UM14, MSU 3

1) Then I need a loop that reads in the attached text file

2) Read the scores by school and determine if MSU or Michigan won or lost

3) - if the wolverines win, have user put the score into the win file (win.txt)

                ** UM win over MSU55-10 **

    - if the wolverines encounter a loss, put the score in the loss file (loss.txt)

               ** wolverines lose to spartans 24-17 **

  NOTE: the permission must be changed on the file in order to write to it

  *** the file permission switching must be done in separate script ***

4) please zip contents of wolverines and sparty directories

In: Computer Science