Questions
The following partially completed T-accounts are for Stanford Corporation: Raw Materials Debit Credit Balance 7,000 (2)...

The following partially completed T-accounts are for Stanford Corporation:

Raw Materials
Debit Credit
Balance 7,000 (2) 24,000
(1) 19,000
Work In Process
Debit Credit
Balance 11,000 (7) ?
(2) 15,000
(4) 18,000
(6) 31,000
Finished Goods
Debit Credit
Balance 18,000
(7) 62,000
15,000
Manufacturing Overhead
Debit Credit
(2) 9,000 (6) 31,000
(3) 16,000
(4) 8,000
(5) 5,000
Accumulated Depreciation--Factory
Debit Credit
Balance 82,000
(3) 16,000
Sales Salaries Expense
Debit Credit
(4) 11,000
Accounts Payable
Debit Credit
Balance
(1) 19,000
(5) 5,000
Salaries and Wages Payable
Debit Credit
Balance 7,000
(4) 37,000

The indirect labor cost is:

In: Accounting

You sold a 105 call for $8 and sold a 95 put for $6 (Short Strangle)....

You sold a 105 call for $8 and sold a 95 put for $6 (Short Strangle). Ignoring transaction costs, your maximum gains, losses and break-even points are respectively:

Question 2 options:

1)

14; unlimited; [81, 119]

2)

8; unlimited; [85, 114]

3)

14; -14; [95, 105]

4)

unlimited; -14; [92, 114]

-----------------------------------------------------------------------------------------------------

Question 4

You bought 150 call for $6 and bought a 150 put for $5 (Long straddle). Ignoring transaction costs, your maximum gains, losses and break-even points are respectively:

Question 4 options:

1)

11; unlimited; [145, 155]

2)

11; -11; [139, 161]

3)

unlimited; -8; [144, 156]

4)

unlimited; -11; [139, 161]

In: Finance

At a recent concert, a survey was conducted that asked a random sample of 20 people...

At a recent concert, a survey was conducted that asked a random sample of 20 people their age and how many concerts they have attended since the beginning of the year. The following data were collected:

Age

62

57

40

49

67

54

43

65

54

41

# of Concerts

6

5

4

3

5

5

2

6

3

1

Age

44

48

55

60

59

63

69

40

38

52

# of Concerts

3

2

4

5

4

5

4

2

1

3

Which of the following is true for this data?

A.

The younger the respondent the more concerts he/she has attended.

B.

The younger the respondent the less concerts he/she has attended.

C.

The relationship between age and the number of concerts attended is insignificant.

In: Statistics and Probability

COMBINATIONS Do the following problems using combinations. 1) How many different 5-player teams can be chosen...

COMBINATIONS

Do the following problems using combinations.

1) How many different 5-player teams can be chosen from eight players?

2) How many 13-card bridge hands can be chosen from a deck of cards?

COMBINATIONS INVOLVING SEVERAL SETS

Following problems involve combinations from several different sets.

1) A club has 4 men, 5 women, 8 boys and 10 girls as members. In how many ways can a group of 2 men, 3 women, 4 boys and 4 girls be chosen?

2) How many 4-letter word sequences consisting of two vowels and two consonants can be made from the letters of the word PHOENIX if no letter is repeated?

In: Statistics and Probability

A restaurant manager is interested in taking a more statistical approach to predicting customer load. She...

A restaurant manager is interested in taking a more statistical approach to predicting customer load. She begins the process by gathering data. One of the restaurant hosts or hostesses is assigned to count customers every five minutes from 7 P.M. until 8 P.M. every Saturday night for three weeks. The data are shown here. After the data are gathered, the manager computes lambda using the data from all three weeks as one data set as a basis for probability analysis.What value of lambda did she find? Assume that these customers randomly arrive and that the arrivals are Poisson distributed. Use the value of lambda computed by the manager and help the manager calculate the probabilities in parts (a) through (e) for any given five-minute interval between 7 P.M. and 8 P.M. on Saturday night. Number of Arrivals Week 1 Week 2 Week 3 3 1 5 6 2 3 4 4 5 6 0 3 2 2 5 3 6 4 1 5 7 5 4 3 1 2 4 0 5 8 3 3 1 3 4 3 a. What is the probability that no customers arrive during any given five-minute interval? b. What is the probability that five or more customers arrive during any given five-minute interval? c. What is the probability that during a 10-minute interval fewer than four customers arrive? d. What is the probability that between four and six (inclusive) customers arrive in any 10-minute interval? e. What is the probability that exactly six customers arrive in any 15-minute interval? *Round your answers to 4 decimal places when calculating using Table A.3. **Round your answer to 4 decimal places, the tolerance is +/-0.0005. a. P(x = 0) = * b. P(x ≥ 5) = * c. P(x < 4 | 10 minutes) = * d. P(4 ≤ x ≤ 6 | 10 minutes) = * e. P(x = 6 | 15 minutes) = **

In: Math

*****NOTE: I DO NOT NEED A DRIVER FILE. I NEED mixed.h AND mixed.cpp********* *****PLEASE MAKE SURE...

*****NOTE: I DO NOT NEED A DRIVER FILE. I NEED mixed.h AND mixed.cpp*********

*****PLEASE MAKE SURE THAT mixed.h AND mixed.cpp WORK WITH THE DRIVER FILE PROVIDED*******************

Objective: Upon completion of this program, you should gain experience with overloading basic operators for use with a C++ class.

The code for this assignment should be portable -- make sure you test with g++ on linprog.cs.fsu.edu before you submit.

Task

Create a class called Mixed. Objects of type Mixed will store and manage rational numbers in a mixed number format (integer part and a fraction part). The class, along with the required operator overloads, should be written in the files "mixed.h" and "mixed.cpp".

Details and Requirements

  1. Your class must allow for storage of rational numbers in a mixed number format. Remember that a mixed number consists of an integer part and a fraction part (like 3 1/2 -- "three and one-half"). The Mixed class must allow for both positive and negative mixed number values. A zero in the denominator of the fraction part constitutes an illegal number and should not be allowed. You should create appropriate member data in your class. All member data must be private.
  2. There should be two constructors. One constructor should take in three parameters, representing the integer part, the numerator, and the denominator (in that order), used to initialize the object. If the mixed number is to be a negative number, the negative should be passed on the first non-zero parameter, but on no others. If the data passed in is invalid (negatives not fitting the rule, or 0 denominator), then simply set the object to represent the value 0. Examples of declarations of objects:
     Mixed m1(3, 4, 5);    // sets object to 3 4/5 
     Mixed m2(-4, 1, 2);   // sets object to -4 1/2 
     Mixed m3(0, -3, 5);   // sets object to -3/5 (integer part is 0). 
     Mixed m4(-1, -2, 4);  // bad parameter combination.  Set object to 0. 
    

    The other constructor should expect a single int parameter with a default value of 0 (so that it also acts as a default constructor). This constructor allows an integer to be passed in and represented as a Mixed object. This means that there is no fractional part. Example declarations:

     Mixed m5(4);  // sets object to 4 (i.e. 4 and no fractional part). 
     Mixed m6;     // sets object to 0 (default)
    
    Note that this last constructor will act as a "conversion constructor", allowing automatic type conversions from type int to type Mixed.
  3. The Mixed class should have public member functions Evaluate(), ToFraction(), and Simplify(). The Evaluate() function should return a double, the others don't return anything. These functions have no parameters. The names must match the ones here exactly. They should do the following:
    • The Evaluate function should return the decimal equivalent of the mixed number.
    • The Simplify function should simplify the mixed number representation to lowest terms. This means that the fraction part should be reduced to lowest terms, and the fraction part should not be an improper fraction (i.e. disregarding any negative signs, the numerator is smaller than the denominator).
    • The ToFraction function should convert the mixed number into fraction form. (This means that the integer part is zero, and the fraction portion may be an improper fraction).
  4. Create an overload of the extraction operator >> for reading mixed numbers from an input stream. The input format for a Mixed number object will be:
     integer numerator/denominator 
    

    i.e. the integer part, a space, and the fraction part (in numerator/denominator form), where the integer, numerator, and denominator parts are all of type int. You may assume that this will always be the format that is entered (i.e. your function does not have to handle entry of incorrect types that would violate this format). However, this function should check the values that come in. In the case of an incorrect entry, just set the Mixed object to represent the number 0, as a default. An incorrect entry occurs if a denominator value of 0 is entered, or if an improper placement of a negative sign is used. Valid entry of a negative number should follow this rule -- if the integer part is non-zero, the negative sign is entered on the integer part; if the integer part is 0, the negative sign is entered on the numerator part (and therefore the negative sign should never be in the denominator). Examples:

     Valid inputs:     2 7/3 , -5 2/7  , 4 0/7  , 0 2/5  , 0 -8/3 
     Invalid inputs:   2 4/0 , -2 -4/5 , 3 -6/3 , 0 2/-3 
    
  5. Create an overload of the insertion operator << for output of Mixed numbers. This should output the mixed number in the same format as above, with the following exceptions: If the object represents a 0, then just display a 0. Otherwise: If the integer part is 0, do not display it. If the fraction part equals 0, do not display it. For negative numbers, the minus sign is always displayed to the left.
     Examples:   0  ,  2  ,  -5  ,  3/4  ,  -6/7  ,  -2 4/5  ,  7 2/3 
    
  6. Create overloads for all 6 of the comparison operators ( < , > , <= , >= , == , != ). Each of these operations should test two objects of type Mixed and return an indication of true or false. You are testing the Mixed numbers for order and/or equality based on the usual meaning of order and equality for numbers. (These functions should not do comparisons by converting the Mixed numbers to decimals -- this could produce round-off errors and may not be completely accurate).
  7. Create operator overloads for the 4 standard arithmetic operations ( + , - , * , / ) , to perform addition, subtraction, multiplication, and division of two mixed numbers. Each of these operators will perform its task on two Mixed objects as operands and will return a Mixed object as a result - using the usual meaning of arithmetic operations on rational numbers. Also, each of these operators should return their result in simplified form. (e.g. return 3 2/3 instead of 3 10/15, for example).
    • In the division operator, if the second operand is 0, this would yield an invalid result. Since we have to return something from the operator, return 0 as a default (even though there is no valid answer in this case). Example:
      Mixed m(1, 2, 3);               // value is 1 2/3
      Mixed z;                        // value is 0
      Mixed r = m / z;                // r is 0 (even though this is not good math)
      
  8. Create overloads for the increment and decrement operators (++ and --). You need to handle both the pre- and post- forms (pre-increment, post-increment, pre-decrement, post-decrement). These operators should have their usual meaning -- increment will add 1 to the Mixed value, decrement will subtract 1. Since this operation involves arithmetic, leave incremented (or decremented) object in simplified form (to be consistent with other arithmetic operations). Example:
      Mixed m1(1, 2, 3);            //  1 2/3
      Mixed m2(2, 1, 2);            //  2 1/2
      cout << m1++;                   //  prints 1 2/3, m1 is now 2 2/3
      cout << ++m1;                   //  prints 3 2/3, m1 is now 3 2/3
      cout << m2--;                   //  prints 2 1/2, m2 is now 1 1/2
      cout << --m2;                   //  prints 1/2  , m2 is now 0 1/2
    
  9. General Requirements
    • As usual, no global variables
    • All member data of the Mixed class must be private
    • Use the const qualifier whenever appropriate
    • The only libraries that may be used in the class files are iostream and iomanip
    • Do not use langauge or library features that are C++11-only
    • Since the only output involved with your class will be in the << overload (and commands to invoke it will come from some main program or other module), your output should match mine exactly when running test programs.

*************DRIVER FILE TO TEST PROGRAM******************

//**Bigginning of main.cpp**//

#include <iostream>
#include "mixed.h"

using namespace std;

int main()
{

  // demonstrate behavior of the two constructors and the << overload

  Mixed x(3,20,6), y(-4,9,2), m1(0,-35,10), m2(-1,-2,4), m3(4), m4(-11), m5;
  char answer;
  cout << "Initial values: \nx = " << x << "\ny = " << y
       << "\nm1 = " << m1 << "\nm2 = " << m2 << "\nm3 = " << m3 
       << "\nm4 = " << m4 << "\nm5 = " << m5 << "\n\n";

  // Trying Simplify
  x.Simplify();
  m1.Simplify();
  cout << "x simplified: " << x << " and m1 simplified " << m1 << "\n\n";

  // Trying ToFraction
  x.ToFraction();
  y.ToFraction();
  m1.ToFraction();
  cout << "Values as fractions: \nx = " << x << "\ny = " << y
       << "\nm1 = " << m1 << "\n\n";
 
  // demonstrate >> overload

  cout << "Enter first number: ";
  cin >> x;
  cout << "Enter second number: ";
  cin >> y;

  cout << "You entered:\n";
  cout << "  x = " << x << '\n';
  cout << "  y = " << y << '\n';

  // demonstrate comparison overloads
  if (x < y) cout << "(x < y) is TRUE\n";
  if (x > y) cout << "(x > y) is TRUE\n";
  if (x <= y)        cout << "(x <= y) is TRUE\n";
  if (x >= y)        cout << "(x >= y) is TRUE\n";
  if (x == y)   cout << "(x == y) is TRUE\n";
  if (x != y)   cout << "(x != y) is TRUE\n";

  // demonstrating Evaluate
  cout << "\nDecimal equivalent of " << x << " is " << x.Evaluate() << '\n';
  cout << "Decimal equivalent of " << y << " is " << y.Evaluate() << "\n\n";

  // demonstrating arithmetic overloads
  cout << "(x + y) = " << x + y << '\n';
  cout << "(x - y) = " << x - y << '\n';
  cout << "(x * y) = " << x * y << '\n';
  cout << "(x / y) = " << x / y << '\n';

  // demonstrating arithmetic that uses conversion constructor
  //  to convert the integer operand to a Mixed object
  cout << "(x + 10) = " << x + 10 << '\n';
  cout << "(x - 4) = " << x - 4 << '\n';
  cout << "(x * -13) = " << x * -13 << '\n';
  cout << "(x / 7) = " << x / 7 << '\n';

  return 0;
}

//**End of main.cpp **//

RESULT OF DRIVER FILE SHOULD PRODUCE THE FOLLOWING OUTPUT:

Initial values: 
x = 3 20/6
y = -4 9/2
m1 = -35/10
m2 = 0
m3 = 4
m4 = -11
m5 = 0

x simplified: 6 1/3 and m1 simplified -3 1/2

Values as fractions: 
x = 19/3
y = -17/2
m1 = -7/2

Enter first number: 1 2/3
Enter second number: 2 3/4
You entered:
  x = 1 2/3
  y = 2 3/4
(x < y) is TRUE
(x <= y) is TRUE
(x != y) is TRUE

Decimal equivalent of 1 2/3 is 1.66667
Decimal equivalent of 2 3/4 is 2.75

(x + y) = 4 5/12
(x - y) = -1 1/12
(x * y) = 4 7/12
(x / y) = 20/33
(x + 10) = 11 2/3
(x - 4) = -2 1/3
(x * -13) = -21 2/3
(x / 7) = 5/21

In: Computer Science

The following are the number of children found in a sample of families denoted as the...

The following are the number of children found in a sample of families denoted as the variable X:

​0, 7, 10, 5, 3, 7, 2, 1, 9, 4, 2, 1, 2, 3, 6, 3, 0, 8, 7, 2, 1

​Find the estimates of the (i) mean of X (ii) the variance of X (iii) the standard deviation of X.

(i)=

(ii)=

(iii)=

In: Statistics and Probability

Consider the following page reference string:5, 1, 5, 5, 3, 6, 2, 3, 0 , 7,...

Consider the following page reference string:5, 1, 5, 5, 3, 6, 2, 3, 0 , 7, 2, 5, 2, 1, 7, 2, 3, 1, 4, 6.Assuming demand paging with three frames, how many page faults would occur for the following replacement algorithms?• LRU replacement• FIFO replacement• Optimal replacement

In: Computer Science

Project: Given an array numbers. We define a running sum of an array as runningSum[i] =...

Project:

Given an array numbers. We define a running sum of an array as runningSum[i] = sum(nums[0]…nums[i]).

Return the running sum of numbers.

Example:

Input: nums = [1,2,3,4]

Output: [1,3,6,10]

Explanation: Running sum is obtained as follows: [1, 1+2, 1+2+3, 1+2+3+4].

You need to do: Create a class called RunningSumArray to perform the main method. Create a class called ArrayOperationto hold the actions for array. In this project, you will need 4methods:

1. Public static Int[] getArray() --- inside ArrayOperationclass, using loop generate a n items array.
2. Public static void runnungSum(int[] inputArray) --- inside ArrayOperation class, process the array to calculate the sums. An array is an object, passing an array to a method is passing by reference.
3. Public static void printArray(int[] result) --- inside ArrayOperation class, print the array in a [1, 2, 3, 4, 5] form.
4. Public static void main(string[] args) --- Prompt user to input a whole number between 5 and 10, using the user input number to generate the array, perform calculation, and print out the array before and after calculation,

In: Computer Science

Times (days) Activity Optimistic Most Likely Pessimistic Preceding Tasks 1 8 10 13 - 2 5...

Times (days)

Activity

Optimistic

Most Likely

Pessimistic

Preceding Tasks

1

8

10

13

-

2

5

6

8

-

3

13

15

21

2

4

10

12

14

1,3

5

11

20

30

4

6

4

5

8

5

7

2

3

4

5

8

4

6

10

7

9

2

3

4

8,6

  1. Draw the AON Network Diagram
  2. Compute the expected activity time
  3. Using the expected activity times, compute the early start, early finish, late start, late finish, and total float for each activity.
  4. Compute the probability of completing the critical path in 69 days.

In: Operations Management