need algorithm not code otherwise will downvote 10
times use ms team or latex code or pdf only
Consider an n-node complete binary tree T, where n = 2d − 1 for
some d. Each node v of T is labeled with a real number xv. You may
assume that the real numbers labeling the nodes are all distinct. A
node v of T is a local minimum if the label xv is less than the
label xw for all nodes w that are joined to v by an edge.
You are given such a complete binary tree T, but the labeling is
only specified in the following implicit way: for each node v, you
can determine the value of xv by probing the node v. Show how to
find a local minimum of T using only O(logn) probes to the nodes of
T.
Note:- dont use handwritten image
In: Computer Science
5. Determine whether the given description corresponds to an experiment or
observational study.
a. A stock analyst selects a stock from a
group of twenty for investment by
choosing the stock with the greatest
earnings per share reported for the
last quarter.
b. A marketing firm does a survey to find out
how many people use a product. Of the one
hundred people contacted, fifteen said
they use the product.
c. A political pollster reports that his
candidate has a 10% lead in the polls
with 10% undecided.
d. A doctor gives a new medication to half of
his patients with the flu and a placebo to
the other half of his patients with the flu.
6. Identify the type of study (cross-sectional, retrospective, prospective)
a. Researchers collect data by
interviewing athletes who have won
Olympic gold medals from 1992 to 2016.
b. A town obtains current employment data
by polling 10,000 of its citizens this
month.
c. A researcher obtains data by searching
through the medical records of 500
men who died of lung cancer
d. A researcher collects data on the progress
of a group of women who diagnosed with
breast cancer 10 years ago.
In: Statistics and Probability
5. In order to diversify your investing strategy, after graduation you decide to also invest annually in Tesla, Inc. You decide to invest $300 every January 1st for 5 years in Tesla and then when you are ready, you will sell this stock and buy your first home.
Date Amount Price
2015 300 240
2016 300 213
2017 300 316
2018 300 333
(1 point) If you sell all of your stock today and the share price is $286, how much money did you receive for the sale of that stock? (2 points) How much money do you Gain or Lose?
6. You decide you want to experiment a little with investing in bonds. Your grandma gives you $1,000 at graduation and you want to put it away in a safe place. You find a government bond to buy. a. (1 points) If the Annual Coupon Rate is 5%, what is your annual coupon payment? b. (3 points) If you assume that the annual discount rate is 4% compounded annually, how much is the bond worth today?
In: Finance
The Bradford Company issued 12% bonds dated January 1, 2016, with a face amount of $20,000,000 on January 1, 2016. The bonds mature on December 31, 2025 (10 years). For bonds of similar risk and maturity the market yield is 10%. Interest is paid semiannually on June 30 and December 31. (FV of $1, PV of $1, FVA of $1, PVA of $1)
Required:
A. Determine the price of the bonds at January 1, 2016.
B. Prepare the journal entry to record their issuance by The Bradford Company on January 1, 2016.
C. Prepare the journal entry to record interest on June 30, 2016 (at effective interest rate).
D. Prepare the journal entry to record interest on December 31, 2016 (at effective interest rate).
In: Accounting
Based on the chart below, prepare the following:
Prepare the following:
-An income statement for 2015 and 2016
-A balance sheet for 2015 and 2016
-Operating cash flows for the two years
-Cash flows from assets in 2016
-Cash flows to creditors for 2016
-Cash flows to stockholders for 2016
| 2015 | 2016 | |||||
| Cost of Goods Sold | 235,942 | 297,915 | ||||
| Cash | 36,542 | 51,940 | ||||
| Depreciation | 61,056 | 69,011 | ||||
| Interest Expense | 13,877 | 15,905 | ||||
| Selling and Admin Exp | 40,952 | 58,569 | ||||
| Accounts Payable | 32,194 | 33,999 | ||||
| Net Fixed Assets | 269,369 | 328,185 | ||||
| Sales | 482,155 | 587,715 | ||||
| Accounts Receivable | 24,120 | 24,089 | ||||
| Notes Payable | 24,866 | 26,972 | ||||
| Long-Term Debt | 142,148 | 161,000 | ||||
| Inventory | 32,766 | 58,798 | ||||
| New Equity | 0 | 16,000 | ||||
In: Accounting
A survey question asked a group of people the following question: "Suppose all you care about is your real income. If you could take your 2016 level of income and live in 1980, or remain in 2016, what would you do?" For example, suppose you made $100,000 per year in 2016. If you could have $100,000 in 1980 or 2016. which would you choose? Some of the people responded they would go back to 1980, while others said they would prefer to stay in 2016.
a. The fact that people were split says what about the goods available for consumption in 1980 and 2016?
b. The fact that people were split says what about the preferences of the people
In: Economics
Cost of Goods Sold Budget
Magnolia Candle Inc. budgeted production of 74,200 candles in 2016. Wax is required to produce a candle. Assume eight ounces (one-half of a pound) of wax is required for each candle. The estimated January 1, 2016, wax inventory is 2,500 pounds. The desired December 31, 2016, wax inventory is 2,100 pounds. Candle wax costs $4.10 per pound.
Each candle requires molding. Assume that 12 minutes are required to mold each candle. Molding labor costs $14.00 per hour.
Prepare a cost of goods sold budget for Magnolia Candle Inc., using the information above. Assume the estimated inventories on January 1, 2016, for finished goods and work in process were $9,800 and $3,600, respectively. Also assume the desired inventories on December 31, 2016, for finished goods and work in process were $12,900 and $3,500, respectively. Factory overhead was budgeted at $109,600. Round your interim calculations to nearest cent, if required.
| Magnolia Candle Inc. | |||
| Cost of Goods Sold Budget | |||
| For the Year Ending December 31, 2016 | |||
| Finished goods inventory, January 1, 2016 | $ | ||
| Work in process inventory, January 1, 2016 | $ | ||
| Direct materials: | |||
| Direct materials inventory, January 1, 2016 | $ | ||
| Direct materials purchases | $ | ||
| Cost of direct materials available for use | $ | ||
| Less direct materials inventory, December 31, 2016 | $ | ||
| Cost of direct materials placed in production | $ | ||
| Direct labor | $ | ||
| Factory overhead | $ | ||
| Total manufacturing costs | $ | ||
| Total work in process during the period | $ | ||
| Less work in process inventory, December 31, 2016 | $ | ||
| Cost of goods manufactured | $ | ||
| Cost of finished goods available for sale | $ | ||
| Less finished goods inventory, December 31, 2016 | $ | ||
| Cost of goods sold | $ | ||
In: Accounting
Question 1
ABC Corp. began operations during November 2016 and sells imported furniture on a retail basis. In December 2016, it sold furniture of $250,000, of which $100,000 was on credit. The cost of furniture that was sold by ABC was $200,000 and this was delivered by the supplier during December. However, the supplier has granted credit terms, according to which ABC paid $50,000 in December 2016 and it is obligated to pay remaining amount in January 2017. In addition to the purchase and sale of furniture in December, ABC paid $10,000 in cash for salaries. Further, ABC incurred utility expense of $15,000 and advertisement cost of $25,000 in December, which will be paid in January, 2017. In December, creditors were paid $50,000 for the furniture purchased and sold in November 2016 (show all your workings).
Question 1
ABC Corp. began operations during November 2016 and sells imported furniture on a retail basis. In December 2016, it sold furniture of $250,000, of which $100,000 was on credit. The cost of furniture that was sold by ABC was $200,000 and this was delivered by the supplier during December. However, the supplier has granted credit terms, according to which ABC paid $50,000 in December 2016 and it is obligated to pay remaining amount in January 2017. In addition to the purchase and sale of furniture in December, ABC paid $10,000 in cash for salaries. Further, ABC incurred utility expense of $15,000 and advertisement cost of $25,000 in December, which will be paid in January, 2017. In December, creditors were paid $50,000 for the furniture purchased and sold in November 2016 (show all your workings).
In: Finance
BinarySearch(A, p, r, V)
if p < r
q = (p + r)/2
if V = A[q]
return q
else if V > A[q]
return BinarySearch(A, q+1, r, V)
else return BinarySearch(A, p, q-1)
else if p = r,
if V = A[p]
return p
else
return -1
return -1
end function
Using this pseudocode, write a function for BinarySearch and also complete the program, by writing a main, which will supply the array A (you may like to use the same main as the other programming exercise you have done so far), and also get an user input for V (which should have same data type as the array itself).
Call the function BinarySearch by sending the array, and 1 for p, N for r and V, store the value in a variable x, which stores the position number of the searched key V.
Then check if x is -1, then display data is not found, otherwise display the value of x, by using a suitable title, saying Data V is found in location x (value of x should be displayed).
Must compile, run and copy and paste the program underneath this word document.
2. a) Construct a Binary Search Tree using the following data:
54 37 17 28 44 71 64 60
b) Illustrate how will you search for 30 from the above tree and how many searches will be needed.
c) Illustrate how you will delete the root from the above tree, redraw the tree after deletion.
d) Add a new data after conducting operation c, say the new value = 50
(Do not start from scratch, show this operation by adding onto existing Tree).
e) Write down the pre-order, post-order and in-order traversal.
In: Computer Science
public class Graph
{
private ST<String, SET<String>> st;
public Graph()
{ st = new ST<String, SET<String>>(); }
public void addEdge(String v, String w)
{ // Put v in w's SET and w in v's SET.
if (!st.contains(v)) st.put(v, new SET<String>());
if (!st.contains(w)) st.put(w, new SET<String>());
st.get(v).add(w);
st.get(w).add(v);
}
public Iterable<String> adjacentTo(String v)
{ return st.get(v); }
public Iterable<String> vertices()
{ return st.keys(); }
// See Exercises 4.5.1-4 for V(), E(), degree(),
// hasVertex(), and hasEdge().
public static void main(String[] args)
{ // Read edges from standard input; print resulting graph.
Graph G = new Graph();
while (!StdIn.isEmpty())
G.addEdge(StdIn.readString(), StdIn.readString());
StdOut.print(G);
}
}
Note: The induced subgraph is the graph comprised of the specified vertices together with all edges from the original graph that connect any two of them.
>more graph.txt
A B
A C
C G
A G
H A
B C
B H
>java SubGraph graph.txt A C G
The graph is
A: B C G H
B: A C H
C: A B G
G: A C
H: A B
The subgraph is
A: C G
C: A G
G: A C
In: Computer Science