Questions
1. Create a class Point which has a template parameter of the type of internal data,...

1. Create a class Point which has a template parameter of the type of internal data, T, and a template parameter for the dimension of the Point(2D, 3D etc.). Store a statically allocated, internal array of type T with dimension n. Ensure to include any constructer(s),destructors, getters or setters you might need.

2. Create a template function which computes the Euclidean distance between 2 points.

3. Instantiate two Point and compute their distance. Instantiate two Point and compute their distance.

Please have a .h and .cpp file and follow the instructions precisely thank you!

Edit: the value for n (size of internal array) should that be 2

In: Computer Science

[Wireshark ] Using the Wireshark program, capture all the network traffic that is related to opening...

  1. [Wireshark ] Using the Wireshark program, capture all the network traffic that is related to opening a webpage of your choice. In order to get maximum benefit/knowledge from the assignment, it’s recommended to choose a non-trivial web portal for the assignment. Using the captured information (Wireshark Capture), answer the questions below. Explain your answer.
    1. Define a display filter that finds the DNS queries and DNS responses. Narrow down the filter so that only these DNS packets are shown that were necessary for opening your chosen webpage (the captured DNS packets that were related to other applications/clients in your computer should be left out of the list).
    2. Define a display filter that finds the TCP packets.
    3. Narrow down the filter even more, so that only these TCP packets are shown that were used to create a new TCP connection(the TCP packets that were following each connection establishment, should be left out of the list).
    4. Using the filter from the previous step, list all the TCP connections that were necessary for opening your chosen webpage. For each TCP connection, explain the following (you can group the connections, to avoid repetitions in your explanations):
    • local(client) TCP port number,
    • remote(server) TCP port number,
    • remote(server) IP address
    • The source and destination MAC address of all the outgoing packets? Whyare all the outgoing packets going to this particular MAC address?
  1. If you can run “traceroute/tracert” between machines in your organization. List three concrete applications to use trace route for cybersecurity?
  1. How to use ”netstate/netstat” to discover malicious activities in your machine?
  1. Install and use Process Monitor “Procmon” (you can download from https://docs.microsoft.com/en-us/sysinternals/ (Links to an external site.)) and then show how to list all running processes that run “RegCreateKey” operation with unsuccessful results.
  1. Show how to use Nmap to do IP scanning using TCP and ICMP and port scanning using Stealth FIN. Show the command and the output.
  1. (extra credit) Use Nessus to discover a vulnerability on a real network

In: Computer Science

Suppose you are an analyst for the Roanoke Software Consulting Company (RSCC), a large consulting firm...

Suppose you are an analyst for the Roanoke Software

Consulting Company (RSCC), a large consulting firm with

offices around the world.

The company wants to build a

new knowledge management system that can identify and

track the expertise of individual consultants anywhere in

the world based on their education and the various

consulting projects on which they have worked

. Assume

that this is a new idea that never done before been

attempted in RSCC or elsewhere. RSCC has an

international network, but the offices in each country may

use somewhat different hardware and software. RSCC

management wants the system up and running within a

year.

In: Computer Science

c++ Write a program that print stars, Max and Min values. It should use the following...

c++

Write a program that print stars, Max and Min values. It should use the following functions:

  1. (2 pts) int getNum ( ) should ask the user for a number and return the number. This function should be called by main once for each number to be entered. Input Validation: Do not accept numbers less than -100.
  2. (2 pts) void printStars ( int n ) should print n number of stars. If n is less than 0, display "Invalid" message instead.
  3. (5 pts) main ( ) should call getNum ( ) function each time to read the user input. Pass each user input into printStars ( ) function to print stars. This function will loop to process series of integers.
    • (2 pts) When the user input is -99, that's a signal to terminate the loop (end of the user inputs (sentinel value)). Remember, sentinel value should not be processed as part of user inputs.
    • (2 pts) main ( ) should also display overall Min and Max values of user inputs.
  4. (1 pt) Write the function prototypes for getNum ( ) and printStars ( ) functions.

Sample runs :

(Bold underlined numbers below are sample user inputs. Your program should display the exact output given the same user inputs)

Please enter a number : -99
Exiting the program....

// restart the program here and the output is as follows: 
Please enter a number : 1
*
Please enter a number : 2
**
Please enter a number : 3
***
Please enter a number : -99

Min = 1, Max = 3
Exiting the program....

// restart the program here and the output is as follows: 
Please enter a number : -1
Invalid
Please enter a number : 10
**********
Please enter a number : -33
Invalid
Please enter a number : 5
*****
Please enter a number : -99

Min = -33, Max = 10
Exiting the program....

In: Computer Science

I'm having a bit of an issue with one of my C++ labs. It's not for...

I'm having a bit of an issue with one of my C++ labs. It's not for score but I need to understand it so I can move on.

A restaurant servers burgers for $8 and salads for $7.

When the customer selects a burger they must choose if they would like cheese. If they do, cheddar costs an additional 25 cents while pepper jack is 50 cents.

When the customer selects a salad they must choose if they would like no dressing, ranch for 10 cents more, and honey mustard for 15 cents more.

Customers can buy a drink for $1.50

Use the question prompts already declared as strings to ask the user for responses and then calculate the total cost the customer owes.

The code I wrote is as follows:

#include <iostream>
using namespace std;

int main() {

   int burgerOrSalad, cheese, kindOfCheese, dressing, drink;
  
   string q1 = "Would you like a 1) burger or 2) a salad?";
   string q2 = "Would you like cheese? 0) No or 1) Yes";
   string q3 = "What kind of cheese 1) Cheddar or 2) Pepper jack?";
   string q4 = "What kind of dressing would you like 0) None, 1) Ranch, 2) Honey Mustard?";
   string q5 = "Would you like a drink? 0) No, 1) Yes";

   cout << q1 << endl;
   cin >> burgerOrSalad;

   double cost = 0;

   cout << q2 << endl;
   cin >> cheese;

   cout << q3 << endl;
   cin >> kindOfCheese;

   cout << q4 << endl;
   cin >> dressing;

   cout << q5 << endl;
   cin >> drink;
    
   if ( burgerOrSalad == 1 ) {
       cost = 8.00;
   }
      if ( cheese == 1 ) {
      }
         else if ( kindOfCheese == 1 ) {
            cost = 8.25;
         }
         else if ( kindOfCheese == 2 ) {
            cost = 8.50;
         }

   if ( burgerOrSalad == 2 ) {
       cost = 7.00;
   }
      else if ( dressing == 1 ) {
         cost = 7.10;
      }
      else if ( dressing == 2 ) {
         cost = 7.15;
      }

   if ( drink == 1 ) {
       cost = 1.50;
   }
   cout << "Total cost of selected meal is " << cost << endl;
   return 0;
}

How can I add the cost if the input is 1 1 1 1?

I'm so lost.

In: Computer Science

Create a c file to read from an existing file one character at a time and...

Create a c file to read from an existing file one character at a time and print that character to the console

Create a c file to read a character from the standard input and write it to a file.

please help me

In: Computer Science

Please no plagiarism and must be in your own 500 words How do you feel blockchain...

Please no plagiarism and must be in your own 500 words

How do you feel blockchain will change the global economy or will it? Explain your answer

In: Computer Science

Write a Java application that checks a string for correct parenthesization. The input comes from the...

Write a Java application that checks a string for correct parenthesization. The input comes from the keyboard and should (but might not) consist solely of the delmiters (, ), [, ], {, and } separated by whitespace.

The output of the program must include following:

  • OK
  • Opener/closer mismatch
  • Missing closer
  • Missing opener
  • Unexpected symbol

The name of your class should be ParenChecker.

For example, if the input was:

( [ { } ] )

the program should produce the following output:

OK

and if the input was:

(

the program should produce the output:

Missing closer

etc...

In: Computer Science

Assume that the following Ada like program compile successfully. int k = 0; A[3] = {0,...

Assume that the following Ada like program compile successfully.

int k = 0;
A[3] = {0, 1, 2};

void f(int p) {
     cout<< A[k];
     p*=3;
     cout<< A[k];
     p*=3;
     cout<< A[k];
}

int main () {
     f(A[k++]);        // postfix
     cout << A[1] << A[2] << endl;
{

   What is printed on the screen assuming?

  1. Pass by value
  2. Pass by reference
  3. Pass by value-result (assume lvalue is computed at call time)
  4. Pass by value-result (assume lvalue is computed at run time)

In: Computer Science

What is IT governance referring to a Company? Why is IT governance important to a company...

What is IT governance referring to a Company?

Why is IT governance important to a company and  How does one implement it.

In: Computer Science

You have been asked to build an admin portal that will allow your company internal employees...


You have been asked to build an admin portal that will allow your company internal employees to access the portal and perform admin functions on behalf of company clients.

Here are additional details:

(a) Admin portal is accessible only on company network to only company employees that have one of the "ADMIN" roles.
(b) Access to the links is role based i.e. only authenticated internal employees with "ADMIN" role are able to access the portal and what links you can access once on the portal is determined based on what other roles you have. So, same link will not be visible to other admin who doesn't have appropriate role to access the link.
(c) There are five categories of applications and 5 admin roles for each category. Here are the details:

#   Category   Role           Access                               Links
====================================================================================================================================================
1.   Global       ADMIN           All Global links                       {Manage User Accounts, Assign Roles, Help Desk}
2.   Finance       FINANCE_ADMIN       All Global links + All Finance Category links           {Finance Reports, Accounts Payable, Accounts Receivables, Tax}
3.   Sales       SALES_ADMIN       All Global links + All Sales Category links           {Sales Reports, Sales Leads, Sales Demo}
4.   HR       HR_ADMIN       All Global links + All HR Category links           {New Hire, On-boarding, Benefits, Payroll, Terminations, HR Reports}
5.   Engineering   ENGG_ADMIN       All Global links + All Engineering Category links       {Application Monitoring, Tech Support, App Development, App Admin, Release Management}

(d) The links redirect users to the admin application that is not developed by you. You are only providing links to the portal and redirect users to appropriate application.

Deliverables:

1. Provide detailed overall solution architecture of the solution that you propose. Discuss each component in the diagram. (Hint: MVC or multi-tier) (40)
IMPORTANT: just high level diagram will NOT suffice. Each component discussion is a must.

2. Use Case diagrams for each function that user can perform. (30)

3. Sequence diagrams for each function that user can perform. (30)

Here are some architecture examples:
https://www.edrawsoft.com/software-architecture-example.php

In: Computer Science

Create 1 HTML page and 1 CSS file for all the styles. Your html page will...

Create 1 HTML page and 1 CSS file for all the styles. Your html page will be a small gallery of images using the Polaroid style. The page should have at least 1 row of 3 images. You can choose any theme of images. Don't pick random images, make them all have a theme. Add an h1 tag for the header of your page. Style the h1 tag with a color, size, and font family. Include a paragraph tag under the h1 tag that is a description of your image gallery. Also style the paragraph with a color and font family.

In: Computer Science

Please write code in c++ using iostream library. Also you can use any string library. Create...

Please write code in c++ using iostream library. Also you can use any string library.

Create structure plane with the following:

1)plane's ID[int type]

2) location[char*]

3) departure time[char*]

Your task is to find the plane with the smallest departure time for the selected city.

Pointer, dynamic array and structures have to be used in this code.

Input:

NOTE: It's just an example of input, you should write code generally for any inputs.

First line contains n(0 < n < 1001)

Then n lines inputed in given format:

First - plane's ID[int type]

Second - location address[char*]

Third - departure time[char*]

Departure city.

example of input:

3

21 LoNdon 23:00

02 Bath 10:00

03 LondoN 22:00

LonDon

Output: example of output: 1_LONDON_22:00 output should be in uppercase

Ouput the information in the following format ID_LOCATION_TIME If there is more that one plane - output with smallest time. If there is no case to go by plane output "Impossible".

In: Computer Science

AND( OR(OR(X,Y), AND(OR(X,Y), OR(NOT(X), NOT(Y)))), OR(OR(X,Y), AND(OR(X,Y), NAND(X,Y))) ) is equivalent to: A. OR(X,Y) B. AND(X,Y)...

AND( OR(OR(X,Y), AND(OR(X,Y), OR(NOT(X), NOT(Y)))), OR(OR(X,Y), AND(OR(X,Y), NAND(X,Y))) )

is equivalent to:

A. OR(X,Y) B. AND(X,Y) C. NOR(X,Y) D. XOR(X,Y) E. NAND(X,Y) F. XNOR(X,Y)

How do I simplify this with the Idempotence, De morgan, absorbtion law, etc and waht are the steps to break it down?

In: Computer Science

Discuss three main information security challenges faced by organizations. Focus on prevention and troubleshooting.

Discuss three main information security challenges faced by organizations. Focus on prevention and troubleshooting.

In: Computer Science