There was an old man with a beard
who said, “It is just as I feared.
Two owls and a hen,
Four larks and a wren
Have all built their nests in my beard”
Edgar Lear
In: Statistics and Probability
In IDLE - Python 3, do the following:
1.
Create File --> New
2. Enter the code below in the new file (you may omit the comments,
I included them for explanation
#Python Code Begin
x = int(input("Enter a
number: "))
y = int(input("Enter
another number: "))
print ("Values before", "x:", x, "y:", y)
#add code to swap
variables here
#you may not use
Python libraries or built in swap functions
#you must use only the
operators you have learned to use in this class so
far
#you may use
additional variables if you wish
print ("Values after ", "x:", x, "y:", y)
#Python Code End
3. File -->Save --> name the M5_FML_Tinker1.py
4. Run --> Run Module
Input: 5 6
Output:
Enter
a number: 5
Enter another number: 6
Values before x: 5 y: 6
Values after x: 6 y: 5
Submission:
1. At the top of your Python code, add a comment with your name at the top of the file
# FirstName LastName
2. Run it one more time to make sure you did not "break" the code.
3. Upload the M5_FML_Tinker.py file
In: Computer Science
Sales plays an important role in allowing a business to maintain long-term relationships with customers. Sales force structures can be critical in allowing companies to distribute their products to their customers effectively. Typical sales force structures include territorial, customer, or product structures. Each structure has pros and cons. In addition, a sales force should be routinely evaluated to determine how effective it is in reaching company sales goals. The choice of how to compensate a sales force, whether through incentives, bonuses, or even contests, may also impact how effective a sales force is.
Imagine that you are the sales manager for a company that makes cabinet hardware, which it has traditionally sold to large contractors who build homes and offices. Your company has built a solid reputation and grown its business regionally, and it is now looking to sell its products to end consumers through national retailers such as Home Depot and Lowes. Your challenge is to create a sales force structure that will meet the expanding role of sales in your company.
In an essay, explain how you would:
structure the sales force. Explain why the structure you recommend is better than alternative approaches. compensate the sales force.
Explain why the approach you recommend would provide the right incentives for the sales force.
In: Operations Management
Question 2 There are 6 cities in Kilroy County. The county must determine where to build central fire stations. The county wants to build the minimum number of central fire stations needed to ensure that at least two fire stations are within 20 minutes (driving time) of each city. The times (in minutes) required to drive between the cities in Kilroy County are given in the table. Formulate a model that will tell Kilroy how many fire stations should be built and where they should be located.
|
From |
To |
|||||
|
City 1 |
City 2 |
City 3 |
City 4 |
City 5 |
City 6 |
|
|
City 1 |
0 |
10 |
20 |
30 |
30 |
20 |
|
City 2 |
10 |
0 |
25 |
35 |
20 |
10 |
|
City 3 |
20 |
25 |
0 |
15 |
30 |
20 |
|
City 4 |
30 |
35 |
15 |
0 |
15 |
25 |
|
City 5 |
30 |
20 |
30 |
15 |
0 |
14 |
|
City 6 |
20 |
10 |
20 |
25 |
14 |
0 |
Decision variables (1 mark):
Objective function (1 mark):
Constraints :
Additional constraint :Either City 1 or City 2 (or both) must be selected to build a fire station in if both City 3 and City 4 are selected to build fire stations in.
In: Statistics and Probability
1) Does Netflix have a strong brand? Offer evidence demonstrating why the firm’s brand is or isn’t strong. How is a strong brand built?
2) Who are the rivals to the Netflix streaming effort? Do any of these firms have advantages that Netflix lacks? What are these advantages?
3) Is Netflix a friend or foe to the studios? Make a list of reasons why they would ‘like’ Netflix, and why studios might be fearful of the firm. What is disintermediation and what incentives do studios have to try to disintermediate Netflix?
4) What advantages does Netflix have over premium cable television channels? What advantages do these channels have over Netflix? Do you think this is a winner-take-all market, or that there is room enough for multiple players?
5)What has been the impact of Netflix move from single plan pricing to separate pricing for streaming and DVD-by-mail? What factors motivated this move? Do you think splitting the service into separate plans was a wise move? Why or why not? What errors did the firm make in the ‘Qwikster debacle’? What could the firm have done differently? Do you think this would have had a positive impact on the firm? Why or why not?
Thank you
In: Operations Management
Braxton Technologies, Inc., constructed a conveyor for A&G
Warehousers that was completed and ready for use on January 1,
2018. A&G paid for the conveyor by issuing a $100,000,
four-year note that specified 4% interest to be paid on December 31
of each year, and the note is to be repaid at the end of four
years. The conveyor was custom-built for A&G, so its cash price
was unknown. By comparison with similar transactions it was
determined that a reasonable interest rate was 12%. (FV of $1, PV
of $1, FVA of $1, PVA of $1, FVAD of $1 and PVAD of $1)
(Use appropriate factor(s) from the tables
provided.)
Required:
1. Prepare the journal entry for A&G’s
purchase of the conveyor on January 1, 2018.
2. Prepare an amortization schedule for the
four-year term of the note.
3. Prepare the journal entry for A&G’s third
interest payment on December 31, 2020.
4. If A&G’s note had been an installment note
to be paid in four equal payments at the end of each year beginning
December 31, 2018, what would be the amount of each
installment?
5. By considering the installment payment of
required 4. Prepare an amortization schedule for the four-year term
of the installment note.
6. Prepare the journal entry for A&G’s third
installment payment on December 31, 2020.
In: Accounting
Can you please tell me what more information I need to provide to solve below problem?
1. Find out below using R
Hints: Use iris dataset from R (built in data set in R)
a) Create a new data frame called virginica.versicolor (that only contains these two species)
the command I used:
virginica.versicolor <- iris[iris$Species %in% c("versicolor", "virginica"), ]
b) What is your null hypothesis regarding sepal lengths for the two species (virginica.versicolor) ? And what is your alternate hypothesis?
c) Describe your hypotheses in terms of your test statistic: what would be the t under the null hypothesis, H0, and what would be the statement about t under your alternate hypothesis Ha?
d) Would you do a one- or non-(i.e., two-sided) directional test? Why?
e) Conduct a Student’s t-test using the formula format as follows:
t.test(sepal.length ~ species, data = virginica.versicolor, var.equal = T).
f) Explain what the three different sections do within the t.test() function.
g) Did your function run a one- or non-directional test?
h) What is your t-value? Based on the results of your t-test, what is your conclusion and why?
In: Math
Language: Python
Function name : sort_by_rating
Parameters : file (.csv file), category (string), order
(boolean)
Returns: None
Description : You want to see what order the items of a particular
category in your file would be in if you sorted them by rating.
Given a file, a category of clothing, and an order boolean (True
for ascending order, False for descending order), create a function
that writes a file called “sorted_items.csv” that includes all of
the items in the specified category in sorted order by
ranking.
The format of the file should look like this:
|
item name |
rating |
|
item name 1 |
rating 1 |
|
item name 2 |
rating 2 |
|
... |
... |
(NOTE: there will be a header row at the top of each .csv file)
Note: If your input file contains no items in the specified
category, your “sorted_items.csv” file should still be created and
have the header row. Also, your written files should end in a new
line character
Hint : You can use the built-in Python .sort() method on a list of
tuples. The tuples will get sorted by the first item in each tuple.
Example:
>>> list_of_tups = [(5, "cats"), (6, "kittens"), (1,
"lizards")] >>> list_of_tups.sort()
>>> print(list_of_tups)
[(1, 'lizards'), (5, 'cats'), (6, 'kittens')]
Test cases:
>>> sort_by_rating("uniqlo.csv","tops",True)
In: Computer Science
QDM Question 2 There are 6 cities in Kilroy County. The county must determine where to build central fire stations. The county wants to build the minimum number of central fire stations needed to ensure that at least two fire stations are within 20 minutes (driving time) of each city. The times (in minutes) required to drive between the cities in Kilroy County are given in the table. Formulate a model that will tell Kilroy how many fire stations should be built and where they should be located.
|
From |
To |
|||||
|
City 1 |
City 2 |
City 3 |
City 4 |
City 5 |
City 6 |
|
|
City 1 |
0 |
10 |
20 |
30 |
30 |
20 |
|
City 2 |
10 |
0 |
25 |
35 |
20 |
10 |
|
City 3 |
20 |
25 |
0 |
15 |
30 |
20 |
|
City 4 |
30 |
35 |
15 |
0 |
15 |
25 |
|
City 5 |
30 |
20 |
30 |
15 |
0 |
14 |
|
City 6 |
20 |
10 |
20 |
25 |
14 |
0 |
Decision variables (1 mark):
Objective function (1 mark):
Constraints :
Additional constraint : Either City 1 or City 2 (or both) must be selected to build a fire station in if both City 3 and City 4 are selected to build fire stations in.
In: Operations Management
Control Flow
1. What is the difference between 10 / 3 and 10 // 3?
2. What is the result of 10 ** 3?
3. Given (x = 1), what will be the value of after we run (x += 2)?
4. How can we round a number?
5. What is the result of float(1)?
6. What is the result of bool(“False”)?
7. What is the result of 10 == “10”?
8. What is the result of “bag” > “apple”?
9. What is the result of not(True or False)?
10. Under what circumstances does the expression 18 <= age < 65 evaluate to True?
Primitive Types
1. What is a variable?
2. What are the primitive built-in types in Python?
3. When should we use “”” (tripe quotes) to define strings?
4. Assuming (name = “John Smith”), what does name[1] return?
5. What about name[-2]?
6. What about name[1:-1]?
7. How to get the length of name?
8. What are the escape sequences in Python?
9. What is the result of f“{2+2}+{10%3}”?
10. What does name.strip() do?
11. How can we check to see if name contains “John”?
12. What are the 3 types of numbers in Python?
In: Computer Science