in C language only.
Write a program called gamecards.c that has a card game logic by comparing the cards from 4 people and calculating which player has the best card.
1. Every card must be represented by exactly
two chars
representing a rank and a suit.
ranks: '2', '3', '4', '5', '6', '7', '8', '9', 'T', 'J', 'Q', 'K', 'A'. ('T' = 10)
Suits: 'H', 'D', 'S', 'C'.
7D represents the “7 of Diamond” etc..
2. Write a function called isRank(char
c) which
calculate if the given character is one of the ranks. It would
return a char with a value of 1 if the character is a valid rank
and 0 if not.
Write a function called isSuit(char c) which
calculate if the given character is one of the suits. It should
return a char with a value of 1 if the character is a valid suit
and 0 if not.
(Lowercase are not valid for both functions)
In: Computer Science
Alpha Taxi & Hauling Company has seven cabs stationed at the railway station. The company has determined that during the late‐evening hours on weeknights, customers request cabs at a rate that follows the Poisson distribution with a mean of 6.6 per hour. Service time is exponential with a mean of 50 minutes per customer. Assume that there is one customer per cab. Using multi‐server model find the following: • Average queue length Lq • Average waiting time Wq • Utilization factor ρ • Probability that there are no customers in the system P0
In: Statistics and Probability
Two bicyclists start racing along a straight road from the same place at the same time in the same direction.
If one travels 40 mi/hr and the other 35 mi/hr, find the distance between them t hours after they start.
In: Math
Cholesterol is vital to human health and well being. It plays an
important
role in the structure, fluidity and permeability of the cell
membrane, and helps
synthesize vitamin D and various hormones. Although cholesterol is
essential for
human health, high levels of cholesterol in the blood stream can
lead to damaged
blood vessels and cardiovascular disease. The cholesterol level in
mg/dl of a
group of Canadian adults is assumed to be normally
distributed.
1. Five individuals are randomly selected from this group. Below
are the
measurements of their cholesterol levels:
120 116 130 132 111
Compute a 95% confidence interval for the mean cholesterol
level.
2. Fifteen individuals are randomly selected from this group.
120 116 130 132 111 122 130 111 143 127 129 135 150 121 112.
Compute a 95% confidence interval for the mean cholesterol
level.
3. Based on these two confidence interval constructions, what do
you conclude?
In: Statistics and Probability
A nine-month European put option on a dividend-paying stock is
currently selling for $2. The stock
price is $25, the strike price is $27, and the risk-free interest
rate is 7% per annum. The stock is expected
to pay a dividend of $1 one month later and another dividend of $1
seven months later. Explain the
arbitrage opportunities available to the arbitrageur by
demonstrating what would happen under
different scenarios.
In: Finance
A nine-month European put option on a dividend-paying stock is currently selling for $2. The stock price is $25, the strike price is $27, and the risk-free interest rate is 7% per annum. The stock is expected to pay a dividend of $1 one month later and another dividend of $1 seven months later. Explain the arbitrage opportunities available to the arbitrageur by demonstrating what would happen under different scenarios.
In: Finance
1. What is the definition of the word Nutrition?
2. Tell me two myths about nutrition and the actual truth.
3. Give me 3 advice about nutrition in Canada.
4. What is the definition of Canada's food guide?
5. Tell me two myths about Canada's food guide and the actual truth.
6. Give me 3 advice using the Canada's food guide.
7. What is the definition of nutritional status?
8. Tell me two myths about nutritional status and their truths.
9. Give me 3 advice about nutritional status in Canada
In: Nursing
Problem 5. Sampling from two populations produced the following results. ?̅ =385 Sx=30 nx =100
?? = 3 7 8 S y = 2 5 n y = 9 0
Find the standard error of (?̅ - ??). Show your calculations.
Find the 90% confidence interval estimate for the difference between the two population means.
Show your calculations.
State clearly the assumption(s) that are necessary for your answer to (b) will be valid.
Interpret your result in (b).
It is claimed that the two population means are not different from each other. Do you reject this
claim? Explain clearly.
In: Statistics and Probability
You offer Donny the choice between two bundles of Coffee (C) and Muffins (M). The
options are(C,M) = (6, 4)and(C,M) = (8, 2), and Donny indicates he prefers the second option.
(a) Write a utility function for Donny that is consistent with his choice.
Suppose you offer him a third option of(C,M) = (7, 6)in addition to the original two, and that Donny indicates he prefers this third option to the first two.
(b) Write a utility function for Donny that is consistent with his choice. It is possible it may be
the same as your answer from part (a).
In: Economics
Two drilling machines(machine A and machine B) can drill deep holes with different diameters on workpieces. The processing time of the two machines are random due to various workpiece materials. Suppose the time it takes machine A to complete drilling one hole is exponentially distributed with mean 1.5,and the time it takes machine B to complete drilling one hole is exponentially distributed with mean 1. If the two machines work independently: 1) what is the probability that machine A completes the work first? 2) What is the probability that machine B completes the work first? 3) Given that machine A completes first, what is the expected amount of time it takes machine A to complete the work? 4) Given that machine A completes last, what is the expected amount of time it takes machine A to complete the work?
In: Statistics and Probability