Questions
Discuss the main characteristics (at least 2-3) of the database approach and how it differs from...

Discuss the main characteristics (at least 2-3) of the database approach and how it differs from traditional file systems. (5 pts) Give examples of systems in which it may make sense to use traditional file processing instead of a database approach. (these examples may come from your day-to-day use of technology)

In: Computer Science

i. Use command ifconfig to find out the IP address of Metasplotiable and record it as...

i. Use command ifconfig to find out the IP address of Metasplotiable and record it as your target_IP.

ii. Open a terminal on Kali and try to login to Metasploitable using the command: ssh root@[target_IP]. Can you log in to the System without providing the password?

iii. Use command nmap to scan all TCP ports on our target machine.

iv. Exploitation: a. Open a terminal on Kali and create a new key pair using ssh-keygen. b. Check if you can mount the target system. c. Mount your target system (Metasploitable) to the NFS. d. Copy the newly generated public key into the target system. e. Dismount the target system.

v. Try to login to the target system without password again.

vi. After login to the target system, do the commands below: whoami hostname date echo “Your name”

1

In: Computer Science

C++ Using what you know about how to take inputs and make outputs to the console,...

C++
Using what you know about how to take inputs and make outputs to the console, create a check printing application. Your application will read in from the user an employee's name and salary, and print out a Console Check similar to the following.

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

> | $1,000,000 | >

> >

> ___Pay to the Order of___ Johnny PayCheck >

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

In: Computer Science

Write a factorial C++ program where n=10,000,000

Write a factorial C++ program where n=10,000,000

In: Computer Science

Write a class file called lastname_digits.java. In it, write a method to compute and return the...

Write a class file called lastname_digits.java. In it, write a method to compute and return the total instances where the sum of digits of the array equals to the target.

Write a demo file called lastname_digits_demo.java. Create an array of random 10 integers between 301 and 999. Also create an integer variable called target that is equal to a value between 5 and 10. Print the answer within this file.

Example:

If five of the 20 integers are equal to 512, 607, 620, 767, 791 and the target is 8. Sum of the four integers is equal to 5+1+2 = 8, 13, 8, 20, 17. Then the total instances where the sum of digits of the array equals to the target is equal to 2.

In: Computer Science

Part One: Write a program to draw a repetitive pattern or outline of a shape using...

Part One: Write a program to draw a repetitive pattern or outline of a shape using for loops and Turtle Graphics. Use the following guidelines to write your program.

  1. Decide on a repetitive pattern or the outline of a shape, such as a house, to draw.
  2. Give your artwork a name. Print the name to the output.
  3. Using for loops and the Turtle Module, draw the outline of a shape or a repetitive pattern.
  4. At least one for loop that repeats three or more times must be used.
  5. Use at least one color apart from black.
  6. Write the pseudocode for this program. Be sure to include any needed input, calculations, and output.

Insert your pseudocode here:

Part Two: Code the program. Use the following guidelines to code your program.

  1. To code the program, use the Python IDLE.
  2. Using comments, type a heading that includes your name, today’s date, and a short description of the program.
  3. Follow the Python style conventions regarding indentation and the use of white space to improve readability.
  4. Use meaningful variable names.

In: Computer Science

Write a “C” program(Linux) that creates a pipe and forks a child process. The parent then...

Write a “C” program(Linux) that creates a pipe and forks a child process. The parent then sends the following message on his side of the pipe “I am your daddy! and my name is <pid-of the-parent-process>\n”, the child receives this message and prints it to its stdout verbatim. The parent then blocks reading on the pipe from the child. The child writes back to its parent through its side ofthe pipe stating “Daddy, my name is <pid-of-the-child>”. The parent then writes the message received from the child to its stdout. Make sure the parent waits on the child exit as to not creating orphans or zombies. Include Makefile.

In: Computer Science

1 of 10 When declaring a jagged array, all dimensions must have the same type. True...

1 of 10

When declaring a jagged array, all dimensions must have the same type.

True
False

Question

2 of 10

What is the maximum number of dimensions you can declare for an array in C#?

3
10
5
There is no maximum.

Question

3 of 10

When you declare a two-dimensional array, you place two numbers within square brackets. What does the first number represent?

Class
Index
Column
Row

Question

4 of 10

When declaring a multidimensional array, all dimensions must have the same type.

True
False

Question

5 of 10

Given the code below, the variables "student1" and "student2" refer to the same memory location.

string student1 = "Student";
string student2 = "Student";

True
False

Question

6 of 10

The code below declares a jagged array.

int[][] jaggedArray = new int[2][];

jaggedArray[0] = new int[20];

jaggedArray[1] = new int[10];

int[0,10] = 95;
int[0][10] = 95;
int[1,11] = 95;
int[1][11] = 95;

Question

7 of 10

Given the code below, what is the output?

string student = " Student";

Console.WriteLine(student.Length)

7
Run-time exception
Compile-time exception
8

Question

8 of 10

Given the code below, what is the output?

string student1 = "Student";

string student2 = "Student";

if(student1 == student2)

{

    Console.WriteLine("True");

}

else

{

    Console.WriteLine("False");

}

True
False

Question

9 of 10

Select the output for the statement below.

int[,] examArray = new int[30, 6];
Console.WriteLine(examArray.GetLength(2));

A compilation error generates.
A run-time error generates.
6
30

Question

10 of 10

You can use multidimensional arrays to store a different number of columns for certain rows.

True
False

In: Computer Science

Given the tables: SKU_DATA (SKU, SKU_Description, Department, Buyer) WAREHOUSE (WarehouseID, WarehouseCity, WarehouseState, Manager, Squarefeet) INVENTORY (WarehouseID,...

  1. Given the tables: SKU_DATA (SKU, SKU_Description, Department, Buyer)

WAREHOUSE (WarehouseID, WarehouseCity, WarehouseState, Manager, Squarefeet)

INVENTORY (WarehouseID, SKU, SKU_Description, QuantityOnHand, QuantityOnOrder)

  1. Write an SQL statement to display SKU and SKU_Description.
  2. Write an SQL statement to display the SKU, SKU_Description, and WarehouseID for products having QuantityOnHand greater than 0. Sort the results in descending order by WarehouseID and ascending order by SKU.
  3. Write an SQL statement to display the SKU, SKU_Description, WarehouseID, WarehouseCity, and WarehouseState for all items stored in the Atlanta, Bangor, or Chicago warehouse
  4. Write an SQL statement to show the SKU, SKU_Description, WarehouseID for all items stored in a warehouse managed by ‘Lucille Smith’. Use a subquery
  5. Write an SQL statement to show the WarehouseID and average QuantityOnHand of all items stored in a warehouse managed by ‘Lucille Smith’.

All for MYSQL Database

In: Computer Science

Convert the following decimal numbers to 32-bit IEEE floating point: 86.59375 -1.59729 Convert the following 32-bit...

Convert the following decimal numbers to 32-bit IEEE floating point: 86.59375 -1.59729

Convert the following 32-bit IEEE floating point numbers to decimal:

0100 1100 1110 0110 1111 1000 0000 0000
1011 0101 1110 0110 1010 0110 0000 0000

In: Computer Science

Question 1: What are the requirements when choosing an identifier for a C# class? Question 2:...

Question 1: What are the requirements when choosing an identifier for a C# class?

Question 2: What are the types of comments supported by C#?

In: Computer Science

Discuss system hardening strategies and techniques including updates and patches, default logon/passwords, anonymous access, removal of...

Discuss system hardening strategies and techniques including updates and patches, default logon/passwords, anonymous access, removal of unneeded services, separation of production and development environments, and settings such as password length and complexity by answering the following questions:

What hardening guidelines or standards are you familiar with?
What steps have you taken to harden systems?
What function do each of the strategies discussed serve?
Research and provide a web link to an article regarding system hardening practices.

In: Computer Science

C++ (1) Prompt the user to enter a string of their choosing (Hint: you will need...

C++

(1) Prompt the user to enter a string of their choosing (Hint: you will need to call the getline() function to read a string consisting of white spaces.) Store the text in a string. Output the string. (1 pt)

Ex:

Enter a sample text:
We'll continue our quest in space.  There will be more shuttle flights and more shuttle crews and,  yes,  more volunteers, more civilians,  more teachers in space.  Nothing ends here;  our hopes and our journeys continue!

You entered: We'll continue our quest in space.  There will be more shuttle flights and more shuttle crews and,  yes,  more volunteers, more civilians,  more teachers in space.  Nothing ends here;  our hopes and our journeys continue!


(2) Implement a PrintMenu() function, which has a string as a parameter, outputs a menu of user options for analyzing/editing the string, and returns the user's entered menu option. Each option is represented by a single character. If an invalid character is entered, continue to prompt for a valid choice. Hint: Implement Quit before implementing other options.

Call PrintMenu() in the main() function. Continue to call PrintMenu() until the user enters q to Quit.

More specifically, the PrintMenu() function will consist of the following steps:

  • print the menu
  • receive an end user's choice of action (until it's valid)
  • call the corresponding function based on the above choice



Ex:

MENU
c - Number of non-whitespace characters
w - Number of words
f - Find text
r - Replace all !'s
s - Shorten spaces
q - Quit

Choose an option:


(3) Implement the GetNumOfNonWSCharacters() function. GetNumOfNonWSCharacters() has a constant string as a parameter and returns the number of characters in the string, excluding all whitespace. Call GetNumOfNonWSCharacters() in the PrintMenu() function.

Ex:

Number of non-whitespace characters: 181


(4) Implement the GetNumOfWords() function. GetNumOfWords() has a constant string as a parameter and returns the number of words in the string. Hint: Words end when a space is reached except for the last word in a sentence. Call GetNumOfWords() in the PrintMenu() function.

Ex:

Number of words: 35


(5) Implement the FindText() function, which has two strings as parameters. The first parameter is the text to be found in the user provided sample text, and the second parameter is the user provided sample text. The function returns the number of instances a word or phrase is found in the string. In the PrintMenu() function, prompt the user for a word or phrase to be found and then call FindText() in the PrintMenu() function. Before the prompt, call cin.ignore() to allow the user to input a new string.

Ex:

Enter a word or phrase to be found:
more
"more" instances: 5


(6) Implement the ReplaceExclamation() function. ReplaceExclamation() has a string parameter and updates the string by replacing each '!' character in the string with a '.' character. ReplaceExclamation() DOES NOT return the revised string. Call ReplaceExclamation() in the PrintMenu() function, and then output the edited string.

Ex.

Edited text: We'll continue our quest in space.  There will be more shuttle flights and more shuttle crews and,  yes,  more volunteers, more civilians,  more teachers in space.  Nothing ends here;  our hopes and our journeys continue.


(7) Implement the ShortenSpace() function. ShortenSpace() has a string parameter and updates the string by replacing all sequences of 2 or more spaces with a single space. ShortenSpace() DOES NOT return the revised string. Call ShortenSpace() in the PrintMenu() function, and then output the edited string.

Ex:

Edited text: We'll continue our quest in space. There will be more shuttle flights and more shuttle crews and, yes, more volunteers, more civilians, more teachers in space. Nothing ends here; our hopes and our journeys continue!

______________________________________________

#include <iostream>
#include <string>
using namespace std;

int main() {

/* Type your code here. */

return 0;
}

In: Computer Science

Project objective: To learn more about OS scheduling through a hands-on simulation programming experience Implement the...

Project objective: To learn more about OS scheduling through a hands-on simulation programming experience

Implement the following 3 CPU scheduling algorithms

  • Simulate and evaluate each with the set of eight processes below.
  • Use any programming language. The program listing should be submitted with the report.
  1. FCFS non-preemptive (partial results provided)
  2. SJF non-preemptive
  3. MLFQ

Multilevel Feedback Queue (absolute priority in higher queues)

            Queue 1 uses RR scheduling with Tq = 5

            Queue 2 uses RR scheduling with Tq = 10

            Queue 3 uses FCFS

All processes enter first queue 1. If time quantum (Tq) expires before CPU burst is complete, the process is downgraded to next lower priority queue. Processes are not downgraded when preempted by a higher queue level process. Once a process has been downgraded, it will not be upgraded.

Assumptions:

  1. All processes are activated at time 0
  2. Assume that no process waits on I/O devices.
  3. After completing an I/O event, a process is transferred to the ready queue.
  4. Waiting time is accumulated while a process waits in the ready queue.
  5. Turnaround time is a total of (Waiting time) + (CPU burst time) + (I/O time)
  6. Response time is the first measure of waiting time from arrival at time 0 until the first time on the CPU.

Process Data:

process goes {CPU burst, I/O time, CPU burst, I/O time, CPU burst, I/O time,…….., last CPU burst}

P1 {5, 27, 3, 31, 5, 43, 4, 18, 6, 22, 4, 26, 3, 24, 4}

P2 {4, 48, 5, 44, 7, 42, 12, 37, 9, 76, 4, 41, 9, 31, 7, 43, 8}

P3 {8, 33, 12, 41, 18, 65, 14, 21, 4, 61, 15, 18, 14, 26, 5, 31, 6}

P4 {3, 35, 4, 41, 5, 45, 3, 51, 4, 61, 5, 54, 6, 82, 5, 77, 3}

P5 {16, 24, 17, 21, 5, 36, 16, 26, 7, 31, 13, 28, 11, 21, 6, 13, 3, 11, 4}

P6 {11, 22, 4, 8, 5, 10, 6, 12, 7, 14, 9, 18, 12, 24, 15, 30, 8}

P7 {14, 46, 17, 41, 11, 42, 15, 21, 4, 32, 7, 19, 16, 33, 10}

P8 {4, 14, 5, 33, 6, 51, 14, 73, 16, 87, 6}

PLEASE CODE IN C++ FOR ALL 3

In: Computer Science

IT can be described as having three waves: automate individual functions, integrate value chains, incorporate IT...

IT can be described as having three waves: automate individual functions, integrate value chains, incorporate IT into product and service offerings. Give an example of each (automate, integrate, incorporate) for specific businesses and cite your sources.

In: Computer Science