Questions
1. A company that wants to send data over the Internet will use an encryption program...

1. A company that wants to send data over the Internet will use an encryption program to ensure data security. All data will be transmitted as four-digit integers. The application should read a four-digit integer entered by the user and encrypt it as follows:  Replace each digit with the remainder of the new value divided by 10 by adding 6 to the digit. Then replace the number in the first digit with the third, and the number in the second digit with the fourth. Print the encrypted integer on the screen.  Write a separate application where an encrypted four-digit integer is entered and decrypted (reversing the encryption scheme) and finds the original number.

Note: code should be written in Java Language.

In: Computer Science

A small metal sphere has a mass of 0.15 g and a charge of -21.0 nC....

A small metal sphere has a mass of 0.15 g and a charge of -21.0 nC. It is 10.0 cm directly above an identical sphere that has the same charge. This lower sphere is fixed and cannot move. If the upper sphere is released, it will begin to fall.

What is the magnitude of its initial acceleration?

In: Physics

To assess your understanding for E- Supply Chain / E- Logistic Management. Q. How to reduce...

To assess your understanding for E- Supply Chain / E- Logistic Management.

Q. How to reduce the organizational risk?

(Min. 250 words)
No Plagiarism (copying) please.

In: Operations Management

I have project the Topic is Home Depot company we need answer this content this point...

I have project the Topic is Home Depot company we need answer this content this point
a) an existing organization’s strategy, structure, systems, and culture
or
b) the design of a new organization’s strategy, structure, systems, and culture.
You will pay particular attention to the follwing aspects of organizational life and design:
1. What are the firm’s mission and strategy?
2. What is the organizational structure? Note: A graphic representation of this structure will help us understand this aspect.
3. How does this design serve the firm’s markets and customers? Can it be improved?
4. What systems are critical to the functioning of this firm? (e.g., HR management software, enterprise systems, balanced score card, etc.)
5. How are teams used and evaluated?

In: Operations Management

Can you provide an example on how a decision tree might be used in practice?

Can you provide an example on how a decision tree might be used in practice?

In: Computer Science

Short answer please Describe the intersection between science and politics. How do they influence each other?...

Short answer please

Describe the intersection between science and politics. How do they influence each other? In your answer, use one example.

Explain how race and social class intersect to affect education outcomes.

Provide definitions of social capital and cultural capital. Create a scenario in which social capital and cultural capital work together to help a student succeed. Create a different scenario in which social capital and cultural capital combine to diminish a student's chances of success.

In: Psychology

what is the difference between idiosyncratic and systemic risk? please give an example of each. which...

what is the difference between idiosyncratic and systemic risk? please give an example of each. which one can be eliminated through diversification? how do we measure a company's systemic risk?

In: Finance

PYTHON - please finish the methods below that are apart of a linkedlist class #return the...

PYTHON - please finish the methods below that are apart of a linkedlist class


#return the data value at index(position) in the list. values remain unchanged
def __getpos__(self, position):
   
    #do not change, checks for valid index
    if self.size == 0:
        raise IndexError
    elif position is None:
        return self.pop(self.size - 1)
    elif type(position) != int:
        raise TypeError
    elif position < 0 or position >= self.size:
        raise IndexError
    

#replace the data value at requested position(index). return nothing
def __setpos__(self,position,value):

    #do not change, checks for valid index
    if self.size == 0:
        raise IndexError
    elif position is None:
        return self.pop(self.size - 1)
    elif type(position) != int:
        raise TypeError
    elif position < 0 or position >= self.size:
        raise IndexError

In: Computer Science

How did the Atlantic system affect Europe, Africa, and the Americas? It is Hist 101 not...

How did the Atlantic system affect Europe, Africa, and the Americas?

It is Hist 101 not Psychology

In: Psychology

Describe the characteristics and benefits of interest rate swaps compared with other forms of interest rate...

Describe the characteristics and benefits of interest rate swaps compared with other forms of interest rate risk management, such as forward rate agreements and interest rate futures


In: Finance

I was supposed to conver a singly linked list to a doubly linked list and everytime...

I was supposed to conver a singly linked list to a doubly linked list and everytime I run my program the output prints a bunch of random numbers constantly until I close the console.

Here is the code.

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdbool.h>

struct node {
int data;

struct node *next;
struct node *prev;
};

//this always points to first link
struct node *head = NULL;

//this always points to last link
struct node *tail = NULL;

//return length of list
int sizeList (struct node *pointer)
{
int length = 0;
struct node *temp;

if(pointer == head)
{
for (temp = head; temp != NULL; temp = temp-> next)
length++;
}
else
{
for (temp = tail; temp != NULL; temp = temp-> prev)
length++;
}
return length;
}

//insert element from last node
struct Node* insertLast (struct node *tail, int newelement)
{
struct node *temp = (struct node*) malloc(sizeof(struct node));
temp-> data = newelement;

if (tail == NULL){
head = temp;
tail = temp;
}
else
{
tail-> next = temp;
temp-> prev = tail;
}
//point last to new last node
tail = temp;

return tail;
};

void printList(struct node *pointer)
{
int length = 0;
struct node *temp;

//check if pointer is head and print head of node
if (pointer == head)
{
for (temp = head; temp != NULL; temp = temp-> next)
printf("%d ", temp-> data);
}
//check if pointer is tail and print the list from tail node using previous pointer
else
{
for (temp = tail; temp != NULL; temp = temp-> prev)
printf("%d ", temp-> data);
}

printf("\n");
}

int get (struct node *pointer, int position)
{
struct node *temp;
int length = sizeList(pointer);
int tempPosition = 0;

if (length < position)
{
printf("Enter the position with in %d.", length);
return -1;
}
//check if pointer is head and return the element from the position
if (pointer == head)
{
for (temp = head; temp != NULL; temp = temp-> next)
{
if(++tempPosition == position)
{
return temp-> data;
}
}
}
//check if pointer is tail and return the element from the position
else
{
for (temp = tail; temp != NULL; temp = tail-> prev)
{
if (++tempPosition == position)
{
return temp-> data;
}
}
}
return 0;
}

//delete node from position
struct node* removeEle(struct node *head, int position)
{
struct node *temp = head, *deleteNode = NULL;
int i;

//traverse list until we get each position
for (i=1; i<position && temp != NULL; i++)
{
temp = temp-> next;
}

//if position is 1, move the head pointer to next and free node and return to head
if (position ==1)
{
deleteNode = temp;
temp = temp-> next;
temp-> prev = NULL;
head = temp;

free (deleteNode);
return head;
}

//if deleteNode is last position move the tail to previous node and free last node
else if (temp == tail)
{
deleteNode = tail;
tail = tail-> prev;
tail-> next = NULL;

free(deleteNode);
return head;
}
//swap temp pointers to skip node
else if (temp != NULL)
{
temp-> prev-> next = temp-> next;
temp-> next-> prev = temp-> prev;

free(temp); //delete n node
return head;
}
else
{
printf("It's an invalid position..\n");
return head;
}
};

void reverseList(struct node *node)
{
//stop and return if node is null
if (!node)
return;

//swap next and prev pointer of node
struct node* temp = node-> next;
node-> next = node-> prev;
node-> prev = temp;

//node of prev is null stop and update head and tail pointer
if(!node-> prev)
{
head = node;
if(head-> next == NULL)
{
tail = head;
}
struct node *temp = head;
while(temp-> next != NULL)
{
temp = temp -> next;
}
tail = temp;
return;
}
//invoke recursive api
reverseList(node-> prev);
}

int main()
{
struct Node *tail = NULL;

//insert element at last
tail = insertLast(tail, 10);
tail = insertLast(tail, 20);
tail = insertLast(tail, 30);
tail = insertLast(tail, 40);
tail = insertLast(tail, 50);

printf("Printing from Head: ");
printList(head);
printf("\n");

printf("Printing from Tail: ");
printList(tail);
printf("\n");

printf("Size of list from Head: %d\n", sizeList(head));
printf("Size of list from Tail: %d\n", sizeList(tail));

//remove element from position 4
printf("Get the element from head at position 4: ");
int element = get(head, 4);

if(element != -1)
{
printf("%d\n", element);
}

//remove element from position 2
printf("Get the element from tail at position 2: ");
element = get(tail, 2);

if(element != -1)
{
printf("%d\n", element);
}

printf("Remove element from position 3\n");
head = removeEle(head, 3);

printf("Printing from Head after removal: ");
printList(head);
printf("\n");

//invoke reverse list
reverseList(head);

printf("Printing from Head after reverseList: ");
printList(head);
printf("\n");

printf("Printing from tail after reverseList: ");
printList(tail);
printf("\n");

return 0;
}

In: Computer Science

Question 1. Your task is to create a full program for a Restaurant of your choice....

Question 1. Your task is to create a full program for a Restaurant of your choice. You will have the output appear at first saying Welcome to ______ Restaurant where the _____ will be whatever you name your restaurant

Today’s choices are 1.__________ 2._________ 3._______ 4.________

NOTE each _____ will say an item and its price for example pizza 2.99 Please choose 1 of the choices. In each case, as the user picks a choice It will calculate the total cost of the item based on a tax of 8.5%(multiply cost by 0.085) and add to original cost It will output what the user chose and the total cost for the bill in correct money format IF the user enters in something other than 1 through 4 it will say. INVALID CHOICE and the cost will be $0.00 It will then say. Thank You and have a nice day!

In: Computer Science

How are elections won? In other words, what distinguishes candidates who win from those who lose?...

How are elections won? In other words, what distinguishes candidates who win from those who lose? Have these factors changed over time? Are the current factors that influence electoral outcomes positive or negative for a democratic society? Explain and provide examples.

In: Psychology

An advertising executive claims that there is a difference in the mean household income for credit...

An advertising executive claims that there is a difference in the mean household income for credit cardholders of Visa Gold and of MasterCard Gold. A random survey of 8 Visa Gold cardholders resulted in a mean household income of $78,320 with a standard deviation of $11,100. A random survey of 12 MasterCard Gold cardholders resulted in a mean household income of $68,070 with a standard deviation of $10,700. Is there enough evidence to support the executive's claim? Let μ1 be the true mean household income for Visa Gold cardholders and μ2 be the true mean household income for MasterCard Gold cardholders. Use a significance level of α=0.05α=0.05 for the test. Assume that the population variances are not equal and that the two populations are normally distributed.

Step 1 of 4: State the null and alternative hypotheses for the test.

Step 2 of 4: Compute the value of the t test statistic. Round your answer to three decimal places.

Step 3 of 4: Determine the decision rule for rejecting the null hypothesis H0H0. Round your answer to three decimal places.

Step 4 of 4: State the test's conclusion.

....reject null hypothesis...fail to reject null hypothesis

In: Math

Suppose your company needs to raise $43 million and you want to issue 30-year bonds for...

Suppose your company needs to raise $43 million and you want to issue 30-year bonds for this purpose. Assume the required return on your bond issue will be 6 percent, and you’re evaluating two issue alternatives: A semiannual coupon bond with a 6 percent coupon rate and a zero coupon bond. Your company’s tax rate is 35 percent. Assume a par value of $1,000

a-1. How many of the coupon bonds would you need to issue to raise the $43 million? (Do not round intermediate calculations and round your answer to the nearest whole number, e.g., 32.)
  Number of coupon bonds
a-2. How many of the zeroes would you need to issue? (Do not round intermediate calculations and round your answer to the nearest whole number, e.g., 32.)
  Number of zero coupon bonds
b-1.

In 30 years, what will your company’s repayment be if you issue the coupon bonds? (Enter your answer in dollars, not millions of dollars, e.g., 1,234,567. Do not round intermediate calculations and round your answer to the nearest whole number, e.g., 32.)

  Coupon bonds repayment $
b-2.

What if you issue the zeroes? (Enter your answer in dollars, not millions of dollars, e.g., 1,234,567. Do not round intermediate calculations and round your answer to the nearest whole number, e.g., 32.)

  Zeroes repayment $

  

c.

Calculate the firm’s aftertax cash outflows for the first year for each bond. (Enter your answers as positive values in dollars, not millions of dollars, e.g., 1,234,567. Do not round intermediate calculations and round your answers to the nearest whole number, e.g., 32.)

  

  Coupon bonds
$
  Zero coupon bonds
$

In: Finance