Questions
information privacy What do you think are the biggest issues facing most people? Have the boundaries...

information privacy

What do you think are the biggest issues facing most people? Have the boundaries shifted too far? Are the benefits of personalized technology worth the loss of privacy? What rights should individuals have over their data? Give examples, be specific.

In: Computer Science

Write a program to read in a collection of integer values, and find and print the...

Write a program to read in a collection of integer values, and find and print the index of the first occurrence and last occurence of the number 12. The program should print an index value of 0 if the number 12 is not found. The index is the sequence number of the data item 12. For example if the eighth data item is the only 12, then the index value 8 should be printed for the first and last occurrence.

The coding language required is Java.

In: Computer Science

Java Data Structures (Stack and Recursion) Using the CODE provided BELOW (WITHOUT IMPORTING any classes from...

Java Data Structures (Stack and Recursion)

Using the CODE provided BELOW (WITHOUT IMPORTING any classes from Java Library) modify the classes and add the following methods to the code provided below.

1. Add a recursive method hmTimes() to the CODE BELOW that states how many times a particular value appears on the stack.

2. Add a recursive method insertE() to the CODE BELOW that allows insert a value at the end of the stack.

3. Add a recursive method popLast() to the CODE BELOW that allows removal of the last node from the stack.

4. Add a recursive method hmNodes() to CODE BELOW that states how many nodes does the stack have.


Prove that every method works, MULTIPLE TIMES, in the MAIN StackWithLinkedList2.

CODE:

class Node {

  int value;

  Node nextNode;

  

  Node(int v, Node n)

  {

    value = v;

nextNode = n;

  }

  

  Node (int v)

  {

     this(v,null);

  }

}

class Stack {

  protected Node top;

  

  Stack()

  {

    top = null;

  }

  

  boolean isEmpty()

  {

    return( top == null);

  }

  void push(int v)

  {

    Node tempPointer;

    tempPointer = new Node(v);

tempPointer.nextNode = top;

top = tempPointer;

  }

  

  int pop()

  {

    int tempValue;

tempValue = top.value;

top = top.nextNode;

return tempValue;

  }   

  

  void printStack()

  {

    Node aPointer = top;

String tempString = "";

while (aPointer != null)

{

tempString = tempString + aPointer.value + "\n";

aPointer = aPointer.nextNode;

}

System.out.println(tempString);

  }

  

  boolean hasValue(int v)

  {

    if (top.value == v)

{

return true;

}

else

{

return hasValueSubList(top,v);

}

  }

  

  boolean hasValueSubList(Node ptr, int v)

  {

    if (ptr.nextNode == null)

{

return false;

}

else if (ptr.nextNode.value == v)

{

return true;

}

else

{

return hasValueSubList(ptr.nextNode,v);

}

  }

}

public class StackWithLinkedList2{

  public static void main(String[] args){

    int popValue;

    Stack myStack = new Stack();

myStack.push(5);

myStack.push(7);

myStack.push(9);

    System.out.println(myStack.hasValue(11));

  }

}

In: Computer Science

HI.... just I want the <tags> of this scenario .... Scenario-based Problem: You are assigned to...

HI.... just I want the <tags> of this scenario ....

Scenario-based Problem:
You are assigned to develop a web based Online Electronic showroom in the Sultanate of oman using HTML 5 with CSS, basic JavaScript and PHP&MySQL. The website should contain the following webpages:

  •  Homepage

  •  Sign In

  •  Sign Up

  •  About Us

  •  Product Details

  •  Feedback

  •  Contact Us

    Following are the details about each page:

    Page-1: HOMEPAGE (Design using Bootstrap)

    This page should have picture/s, background color, text/headings with suitable font with link to all other pages and CSS.

    Page-2: ABOUT US

    This page should have a brief description of the company. This should contain a paragraph with sufficient text color, formatting tags, images, links and CSS.

    Page-3 and 4:Product DETAILS

    Each page should contain Tables with column span and row span, CSS, images, formatting tags, etc. Include any video related to the topic.

    Page-5: SIGN IN (No database)

    This should contain the login form with validations using HTML5, PHP form handling, database connectivity.

    Page-6: SIGN UP

    This should contain the Registration form with validations using JavaScript, PHP form handling, database connectivity. Display the records from the table.

    Page-7: FEEDBACK (No database)

    This should contain the Feedback form with validations using HTML 5 and PHP form handling. Display the feedback.

Page-8: CONTACT US

This should contain a paragraph with sufficient text color, formatting tags, images, links, CSS etc. Note: Kindly refer to the marking scheme for more information and clarity.

In: Computer Science

C++ Question Design and implement a class that stores a list of students. Each student has...

C++ Question

Design and implement a class that stores a list of students. Each student has the list of courses he/she registered for the semester. You will need a container of containers to hold this list of students. Choose the optimal container for this exercise, noting that no duplicates should be permitted. Use STL classes with iterators to navigate the list. Develop a test program, which allows options to add, remove, and list students and their associated course lists. Also include a function that displays the first course name in each list (the function must use iterators) Please use namespace std for this.

In: Computer Science

Explan 4, 5, and 7, using a computer ? The steps for crisis management are: 1-...

Explan 4, 5, and 7, using a computer ?
The steps for crisis management are:
1- Announce and generally publicize the problem.
2- Assign responsibilities and authorities.
3- Update status frequently.
4- Relax resource constrains.
5- Have project personnel operate in burnout mode.
6- Establish a drop-dead date.
7- Clear out nonessential personnel.

In: Computer Science

In Python, generate 30 random values between 0-10 and store it in a list. Print the...

In Python, generate 30 random values between 0-10 and store it in a list. Print the list and the number of occurrences for each value from 0 to 10.

In: Computer Science

Given an array A[1..n] of integers such that A[j] ≥ A[i] − d for every j...

  1. Given an array A[1..n] of integers such that A[j] ≥ A[i] − d for every j > i. That means any inversion pair in A differs in value by at most d. Give an O(n + d) algorithm to sort this array.

In: Computer Science

When programming in the Unix/Linux shell, short-circuit evaluation of an expression is a standard way to...

  1. When programming in the Unix/Linux shell, short-circuit evaluation of an expression is a standard way to execute a second command ONLY IF the first command was successful. How does this work?

  2. What is a ternary operator? When should it be used and when should it be avoided?

  3. We perform a hand trace of a C program to validate what?

In: Computer Science

Convert from twos compliment in 7 bits to base ten (decimal) a. 1100010 b. 0101010

Convert from twos compliment in 7 bits to base ten (decimal)

a. 1100010

b. 0101010

In: Computer Science

Python! Modify the following code to include countries name which should be displaying onto the console...

Python!

Modify the following code to include countries name which should be displaying onto the console from countries with the lowest population to the highest Morroco :38,964, china:1000000000, usa:400,000,000, England:55,000,000.   

class Node:
    def __init__(self,value):
        self.value=value
        self.right=None
        self.left=None
class BinarySearchTree:
    def __init__(self):
        self.root=None
    #adding the element to the bst
    def add(self,value):
        node=Node(value)
        temp=self.root
        flag=1
        while(temp):
            flag=0
            if(node.value>temp.value):
                if(temp.right):
                    temp=temp.right
                else:
                    temp.right=node
                    break
            else:
                if(temp.left):
                    temp=temp.left
                else:
                    temp.left=node
                    break
        if(flag):
            self.root=node
    #pre order traversing
    def preOrder(self,root):
        if(root):
            print(root.value)
            self.preOrder(root.left)
            self.preOrder(root.right)
    #in order traversing
    def inOrder(self,root):
        if(root):
            self.inOrder(root.left)
            print(root.value)
            self.inOrder(root.right)
    #post order traversing
    def postOrder(self,root):
        if(root):
            self.postOrder(root.left)
            self.postOrder(root.right)
            print(root.value)

In: Computer Science

1. When working as a pen-tester, why is it important to stay within the pen-test scope?...

1. When working as a pen-tester, why is it important to stay within the pen-test scope?

2. When working as a pen-tester you determine you have exceeded the scope of your agreement. What should you do next?

3. Is it ok to perform a limited scope pen-test against your bank's servers? (You are an account holder at the bank). Why/Why not and explain your answer.

4. What is the purpose of using nmap during a pen-test?

In: Computer Science

PLEASE ANSWER ALL OF THE FOLLOWING QUESTIONS 2. Describe the networks that might be used to...

PLEASE ANSWER ALL OF THE FOLLOWING QUESTIONS

2. Describe the networks that might be used to support a small family-owned neighborhood convenience store with a point of sale (POS) computer, and an office computer for inventory control, accounting, product acquisition, etc.

3. Describe the distributed applications that might be used to support a neighborhood book store with a coffee shop/browsing area that offers free Internet access to its customers, accepts credit cards for purchases, has an email-based marketing plan, and sells some products online.

4. Describe the networks that might be used to support a small manufacturing facility that supplies widgets to a large international manufacturing firm. The organization uses automation in their production, employs a small management staff (accounting, materials procurement, human resources, etc.), and receives their orders for widgets via electronic communications with the larger firm.

5. Explain the differences between backend LANs, SANs, and backbone LANs

6. List and describe the key components of satellite communications systems

7. In a computer and network security context, list and briefly describe three classes of intruders

8. In a computer and network security context, list and briefly describe three intruder behavior patterns

9. Describe the computing needs of a medium-sized enterprise and the need for client/server, intranet, and/or cloud computing.

10. Conveniently Yours is a small family-owned neighborhood convenience store that sells products and Lottery tickets to a very limited customer base. Their computing equipment is minimal with a point of sale (POS) computer, an office computer for inventory control, accounting, product acquisition, etc. Describe Conveniently Yours computing needs and their possible need for client/server, intranet, and/or cloud computing that would support his business operations.

In: Computer Science

Part 1 (Objective C++ and please have output screenshot) The purpose of this part of the...

Part 1 (Objective C++ and please have output screenshot)

The purpose of this part of the assignment is to give you practice in creating a class. You will develop a program that creates a class for a book. The main program will simply test this class.

The class will have the following data members:

  1. A string for the name of the author
  2. A string for the book title
  3. A long integer for the ISBN

The class will have the following member functions (details about each one are below:)

  1. A default constructor
  2. A Print function which prints out all the information about the book.
  3. A GetData function which reads information from a file into the data members.
  4. A function GetISBN that returns the integer containing the ISBN. (This will be needed in Part 2).

You must create your program using the following three files:

book.h – used for declaring your class. In this header file, the declarations of the class and its members (both data and functions) will be done without the definitions. The definitions should be done in the book.cpp file.

book.cpp – contains the definitions of the member functions:

  1. The default constructor will initialize the author's name to “No name”, the title to "Unknown title", and the ISBN to 0.
  2. The Print function will display all of the information about a book in a clear format. This will be a const function because it does not change the data members. For formatting purposes, you may assume that no name will have more than 20 characters and that no book title will have more than 50 characters.
  3. The GetData function will have the input file as a parameter, will read information from the file and put appropriate values into the data members. (See below for the format of the data file.)
  4. The GetISBN function will simply return the long integer containing the ISBN. It also will be a const function.

Mp8bookDriver.cpp – should contain the main program to test the class.

It should declare two book objects (book1 and book2) using the default constructor. Call the print function for book1 (to show that the default constructor is correct). Open the input file and call the GetData function for book2 and then print its information. Finally, test the GetISBN function for book2 and output the result returned from the function.

Format of Data file
The name of the data file is mp7book.txt
It has data for one book arranged as follows:

  • The name is on one line by itself (hint: use getline).
  • The title is on a line by itself.
  • The ISBN is on the third line.

mp7book.txt

Jane Smith
History Of This World
12349876

Get this part of the program working and save all the files before starting on Part 2. The output should be similar to the following:

Testing the book class by (your name)

The information for book 1 is:
No name Unknown title 0
The information for book 2 is:
Jane Smith History Of The World 12349876
book2 has ISBN 12349876
Press any key to continue

Part 2

Now you will use the book class to create an array of books for a small library. Note that the book.h and book.cpp files should not have to be changed at all - you just have to change the main program in the Mp8bookDriver.cpp file.

There is a new data file, mp7bookarray.txt. It contains the information for the books in the library using the same format as described above for each book. There will be exactly 10 books in the file.

Declare an array of books that could hold 10 book objects. Open the new data file and use a loop to call the GetData function to read the information about the books into the objects in the array. Print out the list of books in the library in a nice format. Notice that the books are arranged in order by ISBN in the data file.

Now imagine customers coming into the library who want to know whether a particular book is in the collection. Each customer knows the ISBN of the book. Open the third data file (mp8bookISBN.txt) which contains ISBN's, read each one, and use a binary search to find out whether the book is in the array. If it is found, print out all the information about the book, if not, print an appropriate message. Then repeat the process for each of the ISBN's until you get to the end of the file.

mp8bookarray.txt

H. M. Deitel
C++ How to Program
130895717
Judy Bishop
Java Gently
201593998
Jeff Salvage
The C++ Coach
201702894
Thomas Wu
Object-Oriented Programming with Java
256254621
Cay Horstmann
Computing Concepts with C++
471164372
Gary Bronson
Program Development and Design
534371302
Joyce Farrell
Object-Oriented Programming
619033614
D. S. Malik
C++ Programming
619062134
James Roberge
Introduction to Programming in C++
669347183
Nell Dale
C++ Plus Data Structures
763714704

mp8bokkISBN.txt
201593998
888899999
763714704
111122222
256254621
130895717
488881111
534371302
619033614

In: Computer Science

Please use R studio Dataset: IBM HR Analytics Employee Attrition & Performance dataset (you can download...

Please use R studio

Dataset: IBM HR Analytics Employee Attrition & Performance dataset (you can download the dataset from kaggle)

Name

Description

ATTRITION

Employee leaving the company (0=no, 1=yes)

BUSINESS TRAVEL

(1=No Travel, 2=Travel Frequently, 3=Tavel Rarely)

DEPARTMENT

(1=HR, 2=R&D, 3=Sales)

EDUCATION FIELD

(1=HR, 2=LIFE SCIENCES, 3=MARKETING, 4=MEDICAL SCIENCES, 5=OTHERS, 6= TEHCNICAL)

GENDER

(1=FEMALE, 0=MALE)

JOB ROLE

(1=HC REP, 2=HR, 3=LAB TECHNICIAN, 4=MANAGER, 5= MANAGING DIRECTOR, 6= REASEARCH DIRECTOR, 7= RESEARCH SCIENTIST, 8=SALES EXECUTIEVE, 9= SALES REPRESENTATIVE)

MARITAL STATUS

(1=DIVORCED, 2=MARRIED, 3=SINGLE)

OVERTIME

(0=NO, 1=YES)

The Variable Attrition is what we plan to use as our dependent variable. The variable contains a Yes if they stay with IBM and 'No' if they do not. We need to creat into a binary dummy variable with 0 if they do not stay with IBM (Attrition = 'No') and 1 if they do stay with IBM (Attrition = 'Yes'). This will also need to be done to the variable Gender and OverTime. Gender we can assign "Male" to zero and "Female" to one. For OverTime we will assign 0 for "No" and 1 for "Yes".

Make Pivot tables instead of correlation matrixes for categorical variables and do the data analysis.

For data analysis:

  • Describe the data using the techniques above (e.g. "We can see in this scatter plot that there is a positive correlation between the number of hours in which the patient exercised per week and his/her weight loss."). About one page without the images.
  • Based on these observations, draw some insights. (e.g. "We believe the patient is burning calories when exercising, thus contributing to the loss of weight"). About one page.
  • State actionable experiments based upon your insights. (e.g. "We will use multiple regression that includes hours exercised as an explanatory variable to model weight loss. We expect...")

In: Computer Science