Questions
(BASH) Say I have an array of strings with about 100 numbers ranging in length from...

(BASH) Say I have an array of strings with about 100 numbers ranging in length from 3-6 that represent some sort of ID. Within the array of strings, there are some duplicates numbers. What I am trying to do is represent only the top 12 numbers in the form (ID, count occurence) where its ranked by the count occurrences. So the first number would not be the ID with the most digits but it would be the one with the most occurrences.  Is there a way to do this with AWK , begin? or how could i approach this problem?

In: Computer Science

Suppose a gas company bases its charges on consumption according to the following table: Gas Charges...

Suppose a gas company bases its charges on consumption according to the following table:

Gas Charges
Gas Used Rate
First 70 cubic meters $5.00 minimum cost
Next 100 cubic meters $0.05 per cubic meter
Next 230 cubic meters $0.025 per cubic meter
Above 400 cubic meters    $0.015 per cubic meter   


Write a program in C++ that asks the user to enter the number of cubic meters of gas used, calculates the charges, and displays the total charge.

In: Computer Science

Hereford Company is planning to introduce a new product with an 80 percent learning rate for...

Hereford Company is planning to introduce a new product with an 80 percent learning rate for production for batches of 1000 unites. The variable labor costs are $30 per unit for the first 1000-unit batch. Each batch requires 100 hours. There are $10,000 in fixed costs not subject to learning. What is the cumulative total time (labor hours) to produce 2,000 units based on the cumulative average-time learning curve?

I know that the answer is 160 hours but I don't understand how to get that answer.

In: Accounting

Demand Estimation Project Fred’s Accounting & Tax services is new but a locally well-known accounting firm...

Demand Estimation Project

Fred’s Accounting & Tax services is new but a locally well-known accounting firm in San Angelo, TX that completes TAX returns for individuals. Every year firms like Fred’s decide how much to charge to complete an individual return.

The price determines how many tax returns firms complete each year. Suppose you are the NEW OFFICE manager at Fred’s who is tasked to determine what your office should charge next year for tax returns.

Since this is all new to you, over a period of time, you’ve tried or experimented with a number of prices when running few specials to try to attract customers. As such, you have the following Price and number of completed returns data.

Use this data to answer the following :

Number of returns completed (Q)

Return Price (P)

932

$70

932

70

910

75

920

75

876

80

852

80

811

85

857

80

847

80

865

80

785

90

802

90

789

95

731

95

663

100

709

100

771

90

792

90

831

85

834

80

  1. Enter the data in an Excel spread sheet and graph the data using a SCATTER plot and insert a Trendline function (Place this graph below data and label both axes).
  2. Using Excel’s Regression analysis, estimate the simple regression (demand for TAX returns) and report the estimated demand equation (you can round the estimated coefficients to 2 or 3 decimal points). Place the regression output in a separate sheet in the same excel file and label the sheet as Reg_Output.
  3. What is the R2 (report this as a percentage), and based on the reported R2 do you think this regression can reasonably be used for analysis?
  4. At the 5% level, how significant is the intercept and the return price variables (report the t-statistics for both)?
  5. How many returns do you expect to be completed if your firm charge $85 per return (round your answer since returns are completed in whole units)?
  6. All else constant, what is the impact on the number of returns demanded if the price of a return increases by $7 (round your answer)?
  7. What is the point price elasticity of demand at the charged price of $85?
  8. At this price (i.e., $85 per return) are you on the elastic, inelastic or unit-elastic portion of your demand function?
  9. Do you recommend an increase, a decrease, or a no change in price (i.e., from the $85 per return) ? How do you justify your recommendation?

In: Economics

Today is 15 November 2018. To construct a portfolio, Jake just purchased two different Treasury bonds,...

Today is 15 November 2018. To construct a portfolio, Jake just purchased two different Treasury bonds, henceforth referred to as Bond A and Bond B. Assume the yield rate for these financial instruments was j2 = 3.15% p.a.

• Bond A has a coupon rate of j2 = 3.05% p.a. and a face value of $100. The maturity date of this bond is 15 May 2020.

• Bond B has a coupon rate of j2 = 2.95% p.a. and a face value of $100. The maturity date of this bond is 15 January 2022.

a. Calculate the duration and the modified duration of Treasury bond A. Give your answer in terms of years, rounded to three decimal places.

b. Calculate the price Jake paid for bond A (rounded to three decimal places).

c. Calculate Jake’s purchase price of bond B using the RBA approach (rounded to three decimal places).

d. Jake purchased 101 units of bond A and 199 units of bond B to establish his portfolio. Based on your results from part a, b and c, calculate th duration of Jake’s portfolio, given that bond B has duration of 3.016 years. Give your answer in terms of years, rounded to two decimal places.

In: Finance

2. (i) Your stockbroker told you about buying stocks on margin last year. You were NOT...

2. (i) Your stockbroker told you about buying stocks on margin last year. You were NOT sure if it is a good investment decision to buy stocks on borrowed funds at the time. You decided to give using margin a try anyway. Your stockbroker bought 100 shares of ABC Corp. on margin for $65 a share. The margin requirement was 60 percent with an interest rate of 6.5 percent on borrowed funds, and commissions on the purchase and sale were 2%. One year after you invested in the stock ABC corp. paid annual dividend of $2 a share and the price of the stock rose to $110 in one year. (12 points)

a. What is the percentage earned on the investment if the stock is bought for cash (i.e., the investor did not use margin)?

b. What is the percentage earned on the investment if the stock is bought on margin?


2 (ii). An investor sells 100 shares short at $22. The sale requires a margin deposit equal to 60 percent of the proceeds of the sale. (8 points)

  1. If the investor closes the position at $30, what was the percentage earned or lost on the investment?

  1. If the position had been closed when the price of the stock was $17, what would have been the percent earned or lost on the position?

In: Finance

ABSORPTION COSTING VERSUS THROUGHPUT COSTING The book The Goal illustrates the concept of throughput costing. For...

ABSORPTION COSTING VERSUS THROUGHPUT COSTING

The book The Goal illustrates the concept of throughput costing. For the problem below
prepare all journal entries and determine the impact on the income statement of the
differences between absorption costing (normal accounting) and throughput costing.
HINT: pay very careful attention to definitions of throughput, inventory and operating
expense from the book
BUDGETED MANUFACTURING COSTS
DIRECT MATERIAL $                 20 PER UNIT
DIRECT LABOR $                   2 PER UNIT
VARIABLE OVERHEAD $                 10 PER UNIT
FIXED OVERHEAD $      150,000
YEAR 1
NO BEGINNING INVENTORY
ACTUAL COSTS OF PRODUCTION EQUALS ABOVE MANUFACTURING COSTS
PURCHASE DIRECT MATERAILS OF $      200,000
INCUR SELLING AND ADMIN COSTS OF $        80,000
#UNITS PRODUCED 10000
# UNITS SOLD 9000
SALES PRICE OF UNITS SOLD $              100
YEAR 2
THERE IS BEGINNIN GINVENTORY
ACTUAL COSTS OF PRODUCTION EQUALS ABOVE MANUFACTURING COSTS
PURCHASE DIRECT MATERAILS OF $      160,000
INCUR SELLING AND ADMIN COSTS OF $        80,000
#UNITS PRODUCED 8000 UNITS
# UNITS SOLD 9000 UNITS
SALES PRICE OF UNITS SOLD $              100



2. CALCULATE THE NET INCOME FOR BOTH YEARS UNDER BOTH COSTING METHODS

In: Accounting

A Treasury Strips is sold for settlement on May 15, 2018.         · Annual Coupon Rate 0%...

A Treasury Strips is sold for settlement on May 15, 2018.

        · Annual Coupon Rate 0%

        · Semi-annual compounding

        · Maturity Date: 15 October 2018

        · Annual Yield-to-Maturity: 6%

        · Face Value: $100

        · Day Count Convention: actual/actual

Calculate the full price of the zero-coupon bond

Hint: Note that in the case of a zero-coupon bond (with $100 par value), our bond pricing formula is simply

where T is the time to maturity in years and P(T) is the (full) pricee of the zero coupon bond.

Note that T is the exact number of years until maturity, including fractions of a year. For example, if a zero-coupon bond matures in 3 years and 15 days (counted using the actual/actual day count convention), then T is 3 + 15/365 = 3.04109589.

1) Calculate the number of days until maturity

2) Calculate the fraction of a year until maturity. Use 366 as the number of days (i.e. divide the number from the previous question by 366). Round your answer to six digits after the decimal.

3) Calculate the full price of the Treasury Strips. Round your answer to six digits after the decimal point (e.g. 98.123456)

In: Finance

Over a 4 year period the Yellow corporation purchased 100% of the outstanding voting shares of...

Over a 4 year period the Yellow corporation purchased 100% of the outstanding voting shares of Green Co. The acquisition was made in a series of steps as follows...

Date % Purchase Price

January, Year 1 5% 5,000

January, Year 2 10% 12,000

January, Year 3   10% 15,000

January, Year 4 75% 200,000

Total 100% 232,000

Any excess of the purchase price over the net book value of the assets was attributed to goodwill.

The acquisition in Year 3 allowed Yellow to have significant influence over the operating policies of Green.

The acquisition in Year 4 gave Yellow control over Green.

Operating results, dividends paid and fair value of White for the 4 years were as follows:

Net Income Dividend Paid Fair Value

January Year 1 100,000

Year 1 25,000 15,000 120,000

Year 2 30,000 15,000 150,000

Year 3 40,000 20,000 170,000

Year 4 50,000 25,000 250,000

For each of the 4 years compute the amount of income that will be record on Yellow's Books related to its Investment in Green Co.

AND compute the balance in the "Investment in Green Co." account on Yellow's books at December 31 of each year.

In: Accounting

Albany High School is planning a field trip for senior students. They expected 100 students to...

Albany High School is planning a field trip for senior students. They expected 100 students to participate in the trip but eventually 130 students join the trip. They planned to charge each student a price of $25 for the trip and spend an expense of $20 per student for the trip. Then, they find that the expense of the filed trip goes up to $30 per student, and they have to increase the price for each student to $40.

Budget Actual

Number of students 100 130

Revenue per student $25 $40

Expense per student $20 $30

(1) What is the expense variance? Is it favorable or unfavorable? How would this variance affect the balance of the budget (aka: the profit)? (Hint: Homework 6 templates might be useful for this question, but you don’t need to follow the templates. No need to consider Quantity (input) in this question.)

(2) What is the revenue variance? Is it favorable or unfavorable? How would this variance affect the balance of the budget (aka: the profit)? (Hint: Homework 6 templates might be useful for this question, but you don’t need to follow the templates. No need to consider the Mix in this question.)

(3) What is the total variance (revenue variance and expense variance together)? Is it favorable or unfavorable? How would this variance affect the balance of the budget (aka: the profit)?

In: Finance