Questions
I need assistance on what I am doing wrong, I've been trying to declare "getRandomLetter" as...

I need assistance on what I am doing wrong, I've been trying to declare "getRandomLetter" as a scope, but haven't found how to all day. It's been about 3+ hours and I still have nothing. Please help fix these and let me know what I am doing wrong (There may be more simple ways of coding all this, but I just need help fixing the errors with current code, thank you). I am trying to have buildAcronym() hold the position of going from A-Z , & as well as getRandomLetter() choose a letter from A-Z using the ASCII character set. This is a bit of the prompt where it asks to set these up. If I am off, I do apologize.

Define and overload two void-typed functions named buildAcronym that assign a (pseudo)-random uppercase letter to two (2) or three (3) character parameters, depending on the version called. Each character in an acronym must be a unique uppercase letter. Two arguments (or three, depending on the version called) will be assigned a random character literal, which can then be printed out in main.

These are my errors.

Acronyms.cpp: In function 'void buildAcronym(char, char, char)':
Acronyms.cpp:13:35: error: 'getRandomLetter' was not declared in this scope
getRandomLetter(a , b , c)
^
Acronyms.cpp: In function 'void buildAcronym(char, char)':
Acronyms.cpp:25:24: error: 'getRandomLetter' was not declared in this scope
getRandomLetter(a,b)
^
Acronyms.cpp: In function 'int main()':
Acronyms.cpp:50:39: error: 'getRandomLetter' was not declared in this scope
cout << getRandomLetter(a,b) ;
^
Acronyms.cpp:56:42: error: 'getRandomletter' was not declared in this scope
cout << getRandomletter(a,b,c);
^
Acronyms.cpp:60:9: error: expected ';' before '{' token
{
^
Acronyms.cpp:67:1: error: expected 'while' at end of input
}
^
Acronyms.cpp:67:1: error: expected '(' at end of input
Acronyms.cpp:67:1: error: expected primary-expression at end of input
Acronyms.cpp:67:1: error: expected ')' at end of input
Acronyms.cpp:67:1: error: expected ';' at end of input
Acronyms.cpp:67:1: error: expected '}' at end of input

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

--

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

(there are 3 lines above include Name: Date: Filename: apologies that it is missing)

#include
using namespace std;


void buildAcronym(char a ,char b , char c)
{
if('A'<= b && 'A' <= b && 'A' <= c && a <= 'Z' && b <= 'Z' && c <= 'Z')
{
getRandomLetter(a , b , c)
{
cout << a + rand() % 65 + 90 << "." ;
cout << b + rand() % 65 + 90 << "." ;
cout << c + rand() % 65 + 90 << "." ;
}
}
return ;
}

void buildAcronym(char a , char b)
{
getRandomLetter(a,b)
{
cout << a + rand() % 65 + 90 << "." ;
cout << b + rand() % 65 + 90 << "." ;
}

return ;
}

int main()
{
char a , b , c ;
int choice ;
do
{
cout << "Press 1 for a two letter acronym, and 2 for a three letter acronym. " ;
cin >> choice ;
switch(choice)
{
case 1 :

if (choice == 1)
{

cout << getRandomLetter(a,b) ;
break ;
}
case 2 :
if (choice == 2)
{
cout << getRandomletter(a,b,c);
break;
}
else (choice != 1 && choice != 2)
{
cout << "Press 1 for a two letter acronym, and 2 for a three letter acronym. ";
}
}while(choice!=1 && choice != 2);

return 0;
}

In: Computer Science

An October 25, 2012 article in the New England Journal of Medicine reports the results of...

An October 25, 2012 article in the New England Journal of Medicine reports the results of a study examining aspirin and survival among patients with colorectal cancer. The following pieces of text are taken directly from the article abstract: (my edits are in italics) “METHODS We obtained data on 964 patients with rectal or colon cancer from the Nurses’ Health Study and the Health Professionals Follow-up Study, including data on aspirin use after diagnosis and the presence or absence of PIK3CA mutation…… RESULTS Among patients with mutated-PIK3CA colorectal cancers, regular use of aspirin after diagnosis was associated with superior colorectal cancer–specific survival (adjusted relative risk for cancer-related death, 0.18; 95% confidence interval [CI], 0.06 to 0.61; P<0.001 by the log-rank test) and overall survival (adjusted relative risk for death from any cause, 0.54; 95% CI, 0.31 to 0.94; P = 0.01 by the log-rank test). In contrast, among patients with wild-type PIK3CA, regular use of aspirin after diagnosis was not associated with colorectal cancer–specific survival (adjusted relative risk, 0.96; 95% CI, 0.69 to 1.32; P = 0.76 by the log-rank test) ) or overall survival (adjusted relative risk, 0.94; 95% CI, 0.75 to 1.17; P = 0.96 by the log-rank test)” The authors present the following graphic as part of the article: (on the next page) Statistical Reasoning in Public Health 1, 2016: Ho

1. What is the outcome of interest for this study?

2. What is the primary predictor of interest for this study?

3. What type of study design is this?

4. Describe the findings with regards to aspirin and survival in patients with colorectal cancer with respect to the presence or absence of the PIK3CA mutation.

5. Even though the authors estimated the association between aspirin and survival separately for the mutated-PIK3CA and wild-type PIK3CA, each of the two associations was adjusted for multiple factors including age, sex, year of diagnosis etc… Why was it potentially necessary to do this adjustment?

In: Nursing

You have been approached by Simpson, a 23 years old fresh graduate for financial advice. Simpson...

You have been approached by Simpson, a 23 years old fresh graduate for financial
advice. Simpson is a risk-taker who has limited knowledge of Finance. He has
provided the following information about his financial situation:

Simpson lives in Auckland and is working full time as a graphic earning $902.35
per week after tax and other deductions.
Simpson is currently renting an apartment, paying $350.00 per week for rent
and utilities.
To purchase basic home furnishing for his apartment, he has just signed a 18-
month contract with Woolies’ Decor on an instalment plan of $90.00 per month.
This contract comes with new home furnishing worth $1620.00.
To finance his car purchase, Simpson has just taken a 5-year car loan for 8,000

with a local financial institution. Interest rate for this car loan is 19.95% per
annum. The market price of this car is estimated to be $6,000.

He also has a hire purchase loan of $2000.00 for a new laptop. He has to settle
this loan over 5 years at 24.9% per annum.
He is spending about $150 per week on food, $60 per week on petrol and $140
per week on entertainment and incidentals.

To complete his degree, Simpson has a student loan of $25,000.00 from NZ
government. Since he is earning over $367 a week before tax, he has started
making payment amounting $225.33 per month towards his loan.


He has accumulated $1523.00 in his Kiwisaver fund.

1/Calculate Simpson’s asset, liability and net worth?

2/Inform Simpson on his weekly income, weekly expenses and weekly savings.

3/Calculate Simpson’s monthly debt safety ratio. Interpret the answer for him.

4/Simpson would like to accumulate $125,000 to buy his first home five years from
now. How much does he has to save each week in order to achieve this goal?
(Assumptions: Interest rate is 4% per annum and compounded weekly, exclude
Kiwisaver)

In: Finance

1\ The Excel file HATCO1 consists of data related to predicting the level of business (Usage...


1\ The Excel file HATCO1 consists of data related to predicting the level of business (Usage Level) obtained from a survey of purchasing managers of customers of an industrial supplier, HATCO. The following are the independent variables.
• Delivery Speed—amount of time it takes to deliver the product once an order is confirmed.
• Price Level—perceived level of price charged by product suppliers.
• Price Flexibility—perceived willingness of HATCO representatives to negotiate price on all types of purchases.
• Manufacturing Image—overall image of the manufacturer or supplier.
• Overall Service—overall level of service necessary for maintaining a satisfactory relationship between supplier and purchaser.
• Sales Force Image—overall image of the manufacturer’s sales force.
• Product Quality—perceived level of quality of a particular product.
• Size of Firm—size relative to others in this market (0 = small; 1 = large) .
Responses to the first seven variables were obtained using a graphic rating scale, where a 10‐cm line was drawn between endpoints labeled “poor” and “excellent.” Respondents indicated their perceptions using a mark on the line, which was measured from the left endpoint. The result was a scale from 0 to 10 rounded to one decimal place.
1) You have been asked to analyze these data. Your analysis should include a descriptive summary of the data using appropriate charts and visual displays, recommendations on whether any interventions are necessary based on the benchmark targets, whether any differences exist between firm size and customer ratings, and between firm size and usage level. Use appropriate hypothesis tests to support your conclusions and summarize your findings in a formal report to the Vice President of Purchasing.
2) Using the tools in this chapter 6 and 7 (regression and forecasting), conduct a complete analysis to predict Usage Level. Be sure to investigate the impact of the categorical variable Size of Firm (coded as 0 for small firms and 1 for large firms) and possible interactions. Also stratify the data by firm size to account for any differences between small and large firms. Write up your results in a formal report to HATCO management.

In: Statistics and Probability

Use the following information to answer questions 1-5. The Aggie Graphics Company was organized on January...

Use the following information to answer questions 1-5.

The Aggie Graphics Company was organized on January 1, 2017.

The trial balance before adjustment at December 31, 2017 contained the following account balances:

Cash $9,500
Accounts Receivable 4,000
Prepaid Insurance 1,800
Equipment 45,000
Accumulated Depreciation 4,500
Accounts Payable 3,500
Notes Payable 18,000
Common Stock 5,000
Retained Earnings 12,000
Dividend 2,000
Graphic Fees Earned 52,100
Consulting Fees Earned 5,000
Salaries Expense 30,000
Supplies Expense 2,700
Advertising Expense 1,900
Rent Expense 1,500
Utilities Expense 1,700
$100,100 $100,100

Analysis reveals the following additional data: (Assume the books are only closed at year end)

(A)    The $2,700 balance in Supplies Expense represents supplies purchased in January. At December 31,  there was $1,200 of supplies on hand.

(B)    The note payable was issued on September 1. It is a 3% 6-month note.

(C)    The balance in Prepaid Insurance is the premium paid on a one-year policy, dated March 1, 2017.

(D)    Consulting Fees are credited to revenue when received. At December 31, consulting fees of $1,000 contracted for January, 2017 have yet to be performed.

(E)    The equipment was purchased on January 1, 2017. It has a 10-year useful life and no salvage value.

The entry to record (A) above would include a debit to: (Assume the company is only making one adjusting entry to record this information)

A.

Supplies for $1,500

B.

Supplies for $1,200

C.

Supply Expense for $1,200

D.

Prepaid Supply Expense for $2,700

1 points   

QUESTION 2

What is the balance in the interest payable account after adjustment?

A.

$ 45

B.

$180

C.

$90

D.

$270

1 points   

QUESTION 3

The correct entry to record (E) above is:

A.

Depreciation Expense               4,500

                Accumulated Depreciation                4,500

B.

Depreciation Expense                9,000

                 Accumulated Depreciation               9,000

C.

Depreciation Expense                9,000

                 Equipment                                        9,000

D.

Depreciation Expense                9,000

                Accumulated Depreciation                4,500

                Equipment                                         4,500

In: Accounting

You will design and implement a graphics program that draws four concentric rectangles in a window,...

You will design and implement a graphics program that draws four concentric rectangles in a window, using four different colors of your choice, meeting the following specifications.

• The size of the window is determined by the user of the program. To be specific, you should prompt the user for both the width and height of the window (in pixels), and then you should set the size of the window using these values. (Hint: use the setup() method of the window.) Make the largest colored rectangle by setting the background color of the window. The three other colored rectangles will be drawn using the draw_rectangle() function described below in Program Design.

• After the first rectangle, the size of each rectangle will be half of the size of the one before it. Using the rectangles shown in the graphic as an example, the length and width of the red rectangle are half of the length and width of the blue rectangle, respectively. Then the length and width of the yellow rectangle are half of the length and width of the red rectangle, respectively, etc.

• You should use a for loop to draw the three rectangles. Because of this, only one line of code in your program should have a call to the function draw_rectangle().

• Use meaningful variable names.

• Use horizontal and vertical white space reasonably and consistently.

• Use named constants as appropriate.

Program Design Your program is to be implemented using the function draw_rectangle(), which draws a rectangle centered in the window of a specified size and color. In order to do this, start your program with exactly the following lines of codes: import turtle import sys sys.setExecutionLimit(60000) # 60 seconds def draw_rectangle(turt, width, height, color): turt.pencolor(color) turt.fillcolor(color) turt.up() x = - width / 2 y = height / 2 turt.goto(x,y) turt.down() turt.begin_fill() # Draw the top turt.setheading(0) turt.forward(width) # Draw the right side turt.right(90) turt.forward(height) # Draw the bottom turt.right(90) turt.forward(width) # Draw the left side turt.right(90) turt.forward(height) turt.end_fill() # Your code goes here

Please explain every step clearly and thoroughly in python, my python code keeps giving an error message.

In: Computer Science

In this​ exercise, you will investigate the relationship between growth and trade. The following table contains...

In this​ exercise, you will investigate the relationship between growth and trade. The following table contains data on average growth rates from 1960 through 1995 for 20 countries along with variables that are potentially related to growth. Download the data from the table by clicking the download table (icon) A detailed description of the variables used in the data set is available here Use a statistical package of your choice to answer the following questions. Run a regression of Growth on TradeShare. Test the null hypothesis H0: β1=0 versus a​ two-sided alternative hypothesis H1: β1≠0. Compute the t​-statistic and p​-value.

The t​-statistic is ______

The P-value is ______

Growth and Tradeshare
TradeShare Growth
0.140501976 1.919793928
0.156622976 0.623148085
0.157703221 4.314143026
0.160405085 2.933687626
0.160815045 1.719106895
0.22145839 0.712664099
0.299405932 2.881528748
0.31307286 2.233843303
0.324612707 0.062417959
0.324745566 -0.65690007
0.329479247 1.976647367
0.330021679 2.941643491
0.337879002 3.228612045
0.339706242 2.437080851
0.352317631 -2.807305485
0.358856708 1.028021609
0.393250912 1.978231803
0.41760394 2.705700033
0.425837249 -2.747544957
0.43557933 0.361157806
0.442142904 2.461462145
0.444374621 2.389435474
0.450546652 1.964281477
0.455769301 1.127964799
0.468346566 1.15945064
0.473254889 2.799286339
0.484600782 -0.874989763
0.488949597 7.16535263
0.509590268 0.93311563
0.517664552 0.605386758
0.527773321 -0.607349105
0.534684658 1.455169378
0.543337107 4.883359156
0.544243515 1.896314241
0.550812602 -0.434996071
0.552722335 1.123864429
0.560642541 2.389975995
0.56074965 2.187123165
0.567130983 1.422135344
0.575274825 2.88970119
0.582814276 0.838475508
0.603035331 2.385760543
0.605031252 1.623378575
0.613616884 3.65261978
0.626079738 0.47131332
0.639484167 3.013142945
0.646913528 2.817210353
0.651203632 0.39235212
0.681555152 3.191976687
0.69943291 -0.330569213
0.704819918 2.508398045
0.729232311 -0.960690243
0.742971599 2.709445427
0.745497823 6.629690402
0.779847086 2.03355754
0.798375845 1.124109103
0.814710021 1.969227155
0.822956383 3.262194952
0.830238342 0.418686175
0.834204197 2.205353259
0.979355395 5.389065361
1.105364204 4.121176915
1.115916967 2.659177524
1.127936959 3.02872879

(show me how to do it please)

In: Economics

Mendoza is considering investing in IBM. However he is captivated by IBM's growth. IBM had made...

Mendoza is considering investing in IBM. However he is captivated by IBM's growth. IBM had made a remarkeable change from a strugling company to a leading company in the personal computer market. Mendoza has asked for your advice as to whether or not the growth is genuine. He suspects there might have been some fraudulent or unethical actions taken by IBM to increase its income. After a rief look at the recent history and performance of IBM, you decide to look more closely at the financial statements. As you review the financial statements, you begin to have some concerns about the nature of IBM's growth. Certain accounting procedures cause you to have doubt as to whether the growth came from IBM's core business operations or from carefully planned accounting adjustments that seem to be unethical. As you proceed in your investigations, you pay particular attention to the following areas. Pensions IBM changed its pension plan to a cash balance plan. The returns of this plan exceeded the amount recognized as an expense. Accounting rules require the company to add the excess returns to earnings but the gains cannot be spent on anything other than pension benefits. IBM increased its earnings per share by making this adjustment. Stock repurchases since 1995, IBM has spent a lot of money making stock repurchases. A stock repurchase may be beneficial to a company by increasing earnings per share since there ill be fewer share holders across which to spread the earnings. You conclude that the financial statements were in accordance with generally accepted accounting principles (GAAP) and you are confident that all accounting rules were followed. However, you have to explain to Mendoza whether the behavior was ehtical. What wiould you tell him?

In: Accounting

Answer should show an understanding of the species concepts and a defensible use of evidence. •...

Answer should show an understanding of the species concepts and a defensible use of evidence.
• Correct definition of species concept
• Selection of evidence that is relevant to the species concept and good explanation of how the evidence is used.
• Clear description of additional evidence that is relevant to the species concept

  1. Two morphs of the marine snail Littorina saxatilis have been identified on rocky intertidal shores in Galacia, Spain. Johannesson et al (1995) made the following observations about these snails:
  • One morph consists of snails with smooth, unbanded shells. These snails are found in the blue mussel zone, low in the intertidal. The other morph consists of snails with ridged, banded shells. These snails are found high in the intertidal, in the barnacle zone.
  • All snails feed on algae, but algal species differ between the two zones.
  • The two morphs overlap in a narrow midshore band at the border of the blue mussel and barnacle zones.
  • Mating in the midshore band is not random. Females prefer to mate with males of the same morph, and only 8% of the snails in the midshore band are hybrids.
  • Some female hybrids have been observed with embryos in their brood pouches, indicating that they are not sterile. However, the survival rates of hybrids relative to the survival rates of pure morphs are unknown.

Consider the information provided in this case study in addressing the questions below.

  1. (2m) Does the case study describe sympatric or allopatric speciation? Explain your answer, including a definition of the mode of speciation that you have identified in this case.
  1. (18m) Are the two morphs separate species:
    • According to the biological species concept?
    • According to the morphological species concept?
    • According to the ecological species concept?

For each species concept, define the species concept, explain what information you used to answer the question and suggest one piece of additional information that would be relevant in helping you to decide if the two morphs are separate species

In: Biology

You are given the data in Table for the US for years 1980 to 1996. (a)...

You are given the data in Table for the US for years 1980 to 1996.
(a) Develop a suitable regression model to explain the male civilian labor force participation rate in relation to male civilian unemployment rate and real average hourly earnings.
(b) Repeat part (a) for females.
(c) Repeat part (a) but use current average hourly earnings.
(d) Repeat part (b) but use current average hourly earnings.
Year CLFPRM CLFPRF UNRM UNRF AHE82 AHE
1980 77.4 51.5 6.9 7.4 7.78 6.66
1981 77 52.1 7.4 7.9 7.69 7.25
1982 76.6 52.6 9.9 9.4 7.68 7.68
1983 76.4 53.9 9.9 9.2 7.79 8.02
1984 76.4 53.6 7.4 7.6 7.8 8.32
1985 76.3 54.5 7 7.4 7.77 8.57
1986 76.3 55.3 6.9 7.1 7.81 8.76
1987 76.2 56 6.2 6.2 7.73 8.98
1988 76.2 56.6 5.5 5.6 7.69 9.28
1989 76.4 57.4 5.2 5.4 7.64 9.66
1990 76.4 57.5 5.7 5.5 7.52 10.01
1991 75.8 57.4 7.2 6.4 7.45 10.32
1992 75.8 57.8 7.9 7 7.41 10.57
1993 75.4 57.9 7.2 6.6 7.39 10.83
1994 75.1 58.8 6.2 6 7.4 11.12
1995 75 58.9 5.6 5.6 7.4 11.44
1996 74.9 59.3 5.4 5.4 7.43 11.82
Key:
CLFPRM: Civilian labor force participation rate, male (%)
CLFPRF: Civilian labor force participation rate, female (%)
UNRM: Civilian unemployment rate, male (%)
UNRF: Civilian unemployment rate, female (%)
AHE82: Average hourly earnings (1982 dollars)
AHE: Average hourly earnings (current dollars)

In: Statistics and Probability