Questions
Suppose your business had an e-commerce web site where it sold goods and accepted credit card...

Suppose your business had an e-commerce web site where it sold goods and accepted credit card payments. Discuss the major security threats to this web site and their potential impact. What can be done to minimize these threats?

In: Computer Science

Asks a user to enter n values, then calculates and returns the minimum, maximum, total, and...

Asks a user to enter n values, then calculates and returns
the minimum, maximum, total, and average of those values.
Use: minimum, maximum, total, average = statistics(n)
-------------------------------------------------------
Parameters:
n - number of values to process (int > 0)
Returns:
minimum - smallest of n values (float)
maximum - largest of n values (float)
total - total of n values (float)
average - average of n values (float)
---------------------------------------

In: Computer Science

Problem 10 Write down the running time function, T(n), of the program below. def prob10(L): s...

Problem 10 Write down the running time function, T(n), of the program below.

def prob10(L):
    s = 0
    for x in L:
        for y in L:
            if x+y % 10 == 0:
                print(x, y, x+y)
                s = s + x*y
    return s

ANSWER:

T(n) = ...

***Big-O, Omega, Theta complexity of functions, Running time equations of iterative functions & recursive functions,  Substitution method & Master theorem

Please answer within these topics.***

In: Computer Science

Create a program that determines the name of the person with the highest or lowest number...

Create a program that determines the name of the person with the highest or lowest number of votes. The data will be in two arrays. The first array is of type String and has the following names in it: Mike Muldune Justin Meiber Clark Kent Ana Karina The second array is of type integer and has the following numbers in it: 2324, 2425, 3344 and 2526. Ask the user to enter a 1 for highest and 2 for lowest. If the user enters a 1, print the name of the person with the highest number of votes and the number of votes received. It the user enters a 2, print the name of the person with the lowest number of votes and the number of votes received.

In: Computer Science

Write the following questions as queries in Relational Algebra. Use only the operators discussed in class...

Write the following questions as queries in Relational Algebra. Use only the operators discussed in class (select, project, Cartesian product, join, union, intersection, set difference and renaming —in particular, no outer joins or aggregations). Type your answers. If you can’t find Greek letters in your word processor, you can simply write out the operator, all uppercase (i.e. ’SELECT’). Please use renaming consistently, as indicated in the handout. Before starting, make sure you understand the schema of the database. If you are in doubt about it, please ask the instructor.

Assume a database with schema:

ACTOR(name,age,address,nationality)

MOVIE(title,year,genre,budget,director-name,studio)

APPEARS(name,title,salary)

Write the following questions in Relational Algebra:

1. List the titles and budgets of movies where actor Keanu Reeves appeared in 1999.

2. List the names and ages of actors who have appeared in a comedy produced by Studio ’MGM’.

3. List the names of directors who have directed a drama or a comedy.

4. List the names of directors who have directed a drama and a comedy.

5. List pairs of actors who have appeared together in a movie (note: the schema of your answer should be (name1,name2), where both name1 and name2 are names of actors.

In: Computer Science

For example My IP address 128. 0. 0. 1 My IP address 53. 20. 62. 201...

For example

My IP address 128. 0. 0. 1

My IP address 53. 20. 62. 201

My IP address 77. 122. 180. 76

My IP address 54. 33. 11. 11

My IP address 33. 33. 2. 11

My IP address 202. 29. 205. 69

My IP address 215. 18. 15. 185

My IP address 56. 66. 33. 30

How do you write a regular expression that covers all IP addresses and display all list using a loop in Python

In: Computer Science

Write the method: public static String removeSubstring(String s1, String s2) Method removeSubstring(String s1, String s2) Must...

Write the method: public static String removeSubstring(String s1, String s2) Method removeSubstring(String s1, String s2)

Must do 3 things:
1. Take two parameters, the original String (String s1) and the substring (String s2) that is to be removed;
2. Create a new String that consists of the original String data less all occurrences of the substring data;
3. Return the new String.

Note:
1. The data to be removed is each occurrence of the complete substring, not individual characters of the substring. For example, if the original String is “hello” and the substring is “el”, the String to be returned is “hlo” and not “ho”.
2. The second, third and fourth examples include spaces, so the substring also includes a space that is to be removed.

PLEASE HELP ME UNDERSTAND HOW TO COMPLETE THIS CODE BELOW:

public class RemoveSubstring
{
   public static void main(String [] args)
   {

   String testString1 = "173167176531317";
   String subStr1 = "17";
  
   String testString2 = "I am not happy";
   String subStr2 = "not ";
  
   String testString3 = "I am not happy and not glad";
   String subStr3 = "not ";
  
   String testString4 = "neither this nor that works!";
   String subStr4 = "neither this nor ";
  
   System.out.println("The string " + testString1 + " without " + subStr1 + " is: " + removeSubstring(testString1, subStr1));
   System.out.println("The string " + testString2 + " without " + subStr2 + " is: " + removeSubstring(testString2, subStr2));
   System.out.println("The string " + testString3 + " without " + subStr3 + " is: " + removeSubstring(testString3, subStr3));
   System.out.println("The string " + testString4 + " without " + subStr4 + " is: " + removeSubstring(testString4, subStr4));

   }

   public static String removeSubstring(String s1, String s2)
   {
  
return("PLEASE HELP ME UNDERSTAND HOW THIS WORKS OR WHERE TO LEARN MORE I AM LOST HERE THANK YOU");
   }

}

In: Computer Science

2. Explain why it is important to develop an effective data governance program What industries can...

2. Explain why it is important to develop an effective data governance program

What industries can you think of that might have strict data governance regulations in place?

What are the advantages of good data governance?

What are the characteristics of weak or non-existent data governance?

3. How can virtualization reduce IT costs while improving performance?

4. Discuss your own experiences with virtualization. Do you have any?

5. How does virtualization lead us to cloud computing?

6. Do you see Cloud as a form of outsourcing, or is it more than that?

7. what is your understanding of the 3 main delivery models?

8. What aspects of any of the 3 main delivery models do you utilize personally, or through

work?

9. What disadvantages can you see with cloud computing?

In: Computer Science

Write a program that reads in a single integer. Display a message depending on what is...

Write a program that reads in a single integer.

Display a message depending on what is given:

  • When the number is 42, output "42 is the Ultimate Question of Life, the Universe, and Everything."
  • When the number is 2020 output "2020 is the current year."
  • When the number is greater than 1000 and less than 3000 output "1500 could be a year." where 1500 is the number the user originally inputted
  • When none of the above, output "no idea."

One example shown below with the user input highlighted:

Give a number: 2020
2020 is the current year.
-- Font family -- -- Font size --

In: Computer Science

1. The following program has syntactic errors. Identify the errors and correct them. Compile the corrected...

1. The following program has syntactic errors. Identify the errors and correct them.

Compile the corrected program and submit a screeshot showing that the program has 0 (zero) errors.

You can use  https://repl.it/languages/c  or  https://www.onlinegdb.com/

#include <stdio.h>

int main (Void)

{

      INT sum;

      /* Compute result

      sum = 25 + 37 - 19;

      // Display result

      printf (“The answer is %i\n”, sum);

      return 0;

} // main

2. What is the purpose of a variable?

a.

To assign values

b.

To perform calculations

c.

To hold a value

d.

To hold a constant value

In: Computer Science

Data science use in construction required in typed words contain at least 1000 words

Data science use in construction

required in typed

words contain at least 1000 words

In: Computer Science

what aggregate functions priobably would be usefull to school administrators to analyze student population and why?...

what aggregate functions priobably would be usefull to school administrators to analyze student population and why? (school environment database management)

In: Computer Science

Iterative Process a. What is meant by the iterative development process? Briefly explain its key attributes...

Iterative Process

a. What is meant by the iterative development process? Briefly explain its key attributes and benefits .

b. What is the Agile Manifesto and what are some of its key values? explain at least 2 values in terms of their implications on the agile model.

In: Computer Science

NOTE give complete and accurate answers FOR 30 marks 1(a) A Give the output for the(2*5)...

NOTE give complete and accurate answers FOR 30 marks

1(a) A Give the output for the(2*5)

array([ 0, 1, 8, 27, 64, 125, 216, 343, 512, 729])

a. a[:6:2] = -1000 (ii) a[ : :-1] )

b. Display the values of 1D array using for loop?


c. Write a code to print a 3D array?


d. How to print the transpose of a 2D array?


e Write a function to sort the array row and coloumn wise ?

(b) You are the class representative and your class advisor always requests your help to prepare the result analysis after each internal assessment. One of the tasks that your class advisor has assigned to you is to find whether a student has scored a 0 in a course.Given the scores of the 'n' students in the class, write a python program to find whether how many students have scored a zero in a course. Use arrays to store the marks of the students and assume that the maximum number of students in a class is 50.(5)

(c) Normally in all engineering colleges, there will be a long vacation after every even semester and a short vacation after every odd semester.Create a program in python to determine whether he will have a long vacation or short vacation at the end of a particular semester.(5)

(d) Design a 2D array to store the marks of six subjects of a student and display its total marks and average percentage?(5)

(e) Differentiate between VIEW and COPY?(5)

A Give the output for the(2*5)

array([ 0, 1, 8, 27, 64, 125, 216, 343, 512, 729])

a. a[:6:2] = -1000 (ii) a[ : :-1] )

b. Display the values of 1D array using for loop?


c. Write a code to print a 3D array?


d. How to print the transpose of a 2D array?


e Write a function to sort the array row and coloumn wise ?

Q2. You are the class representative and your class advisor always requests your help to prepare the result analysis after each internal assessment. One of the tasks that your class advisor has assigned to you is to find whether a student has scored a 0 in a course.Given the scores of the 'n' students in the class, write a python program to find whether how many students have scored a zero in a course. Use arrays to store the marks of the students and assume that the maximum number of students in a class is 50.(5)

Q3 Normally in all engineering colleges, there will be a long vacation after every even semester and a short vacation after every odd semester.Create a program in python to determine whether he will have a long vacation or short vacation at the end of a particular semester.(5)

Q4 Design a 2D array to store the marks of six subjects of a student and display its total marks and average percentage?(5)

Q5 Differentiate between VIEW and COPY?(5)

A Give the output for the(2*5)

array([ 0, 1, 8, 27, 64, 125, 216, 343, 512, 729])

a. a[:6:2] = -1000 (ii) a[ : :-1] )

b. Display the values of 1D array using for loop?


c. Write a code to print a 3D array?


d. How to print the transpose of a 2D array?


e Write a function to sort the array row and coloumn wise ?

Q2. You are the class representative and your class advisor always requests your help to prepare the result analysis after each internal assessment. One of the tasks that your class advisor has assigned to you is to find whether a student has scored a 0 in a course.Given the scores of the 'n' students in the class, write a python program to find whether how many students have scored a zero in a course. Use arrays to store the marks of the students and assume that the maximum number of students in a class is 50.(5)

Q3 Normally in all engineering colleges, there will be a long vacation after every even semester and a short vacation after every odd semester.Create a program in python to determine whether he will have a long vacation or short vacation at the end of a particular semester.(5)

Q4 Design a 2D array to store the marks of six subjects of a student and display its total marks and average percentage?(5)

Q5 Differentiate between VIEW and COPY?(5)

A Give the output for the(2*5)

array([ 0, 1, 8, 27, 64, 125, 216, 343, 512, 729])

a. a[:6:2] = -1000 (ii) a[ : :-1] )

b. Display the values of 1D array using for loop?


c. Write a code to print a 3D array?


d. How to print the transpose of a 2D array?


e Write a function to sort the array row and coloumn wise ?

Q2. You are the class representative and your class advisor always requests your help to prepare the result analysis after each internal assessment. One of the tasks that your class advisor has assigned to you is to find whether a student has scored a 0 in a course.Given the scores of the 'n' students in the class, write a python program to find whether how many students have scored a zero in a course. Use arrays to store the marks of the students and assume that the maximum number of students in a class is 50.(5)

Q3 Normally in all engineering colleges, there will be a long vacation after every even semester and a short vacation after every odd semester.Create a program in python to determine whether he will have a long vacation or short vacation at the end of a particular semester.(5)

Q4 Design a 2D array to store the marks of six subjects of a student and display its total marks and average percentage?(5)

Q5 Differentiate between VIEW and COPY?(5)

A Give the output for the(2*5)

array([ 0, 1, 8, 27, 64, 125, 216, 343, 512, 729])

a. a[:6:2] = -1000 (ii) a[ : :-1] )

b. Display the values of 1D array using for loop?


c. Write a code to print a 3D array?


d. How to print the transpose of a 2D array?


e Write a function to sort the array row and coloumn wise ?

Q2. You are the class representative and your class advisor always requests your help to prepare the result analysis after each internal assessment. One of the tasks that your class advisor has assigned to you is to find whether a student has scored a 0 in a course.Given the scores of the 'n' students in the class, write a python program to find whether how many students have scored a zero in a course. Use arrays to store the marks of the students and assume that the maximum number of students in a class is 50.(5)

Q3 Normally in all engineering colleges, there will be a long vacation after every even semester and a short vacation after every odd semester.Create a program in python to determine whether he will have a long vacation or short vacation at the end of a particular semester.(5)

Q4 Design a 2D array to store the marks of six subjects of a student and display its total marks and average percentage?(5)

Q5 Differentiate between VIEW and COPY?(5)


This is a python assignment

In: Computer Science

Copy the following Python fuction discussed in class into your file: from random import * def...

Copy the following Python fuction discussed in class into your file:

from random import *
def makeRandomList(size, bound):
    a = []
    for i in range(size):
        a.append(randint(0, bound))
    return a

a. Add another function that receives a list as a parameter and computes the sum of the elements of the list. The header of the function should be

def sumList(a):

The function should return the result and not print it. If the list is empty, the function should return 0. Use a for loop iterating over the list.

Test the function in the console to see if it works.

b. Write a function that receives a list as a parameter and a value, and returns True if the value can be found in the list, and Falseif not. Use a for loop that goes over the list and compares each element to the value. If any of them is equal to the value, it returns True. Otherwise after the loop is done, you can return False. Thus, if the loop completes without a return statement happening, then the value is not in the list. The function header should look like this:

def searchList(a, val):

Test this second function a few times the same way as the first one.

c. Below the three functions, add a piece of code that

  • calls the function makeRandomList to generate a list with a size of 10 and a bound of 50, stores it in a variable, and prints it.
  • Then it should call the function sumList to compute the sum and also print the result.
  • Finally, it should ask the user for a value, input it and store it in a variable, then call the function searchList with the list and this variable, and output the result.

Test the program to make sure that it works fine.

In: Computer Science