Take the Java program Pretty.java and convert it to the equivalent C program. You can use the file in.txt as sample input for your program.
v import java.io.*;
import java.util.*;
public class Pretty
{
public static final int LINE_SIZE = 50;
public static void main(String[] parms)
{
String inputLine;
int position = 1;
Scanner fileIn = new Scanner(System.in);
while (fileIn.hasNextLine())
{
inputLine = fileIn.nextLine();
if (inputLine.equals(""))
{
if (position > 1)
{
System.out.println();
}
System.out.println();
position = 1;
}
else
{
if ((position+inputLine.length()-1) > LINE_SIZE)
{
System.out.println();
position = 1;
}
System.out.print(inputLine);
position += inputLine.length();
if (position <= LINE_SIZE)
{ // add a blank after the current word
System.out.print(" ");
position++;
}
}
}
}
}
In: Computer Science
Choose a Texas Governor, any Governor (current or past). Write a short biographical essay of your chosen governor. You should include: 1. Where he or she was born. 2. Where he or she was educated. 3. What affect (if any) might where he or she was born and educated may have had on their political ideology. 4. Party affiliation? 5. Significant legislative development during his/her administration(s) 6. Significant legislative battles during his/her administration(s) * 500 minimum word count * Appropriate in-text citations where necessary * At least 2 bibliographic references
In: Economics
A patient has just fallen in the hospital unit where you work and fractured their skull. A team of personnel are asked to collaborate and develop a fall prevention program that includes using the Morse Fall Scale.
Identify the members included on the team and why they are important to include.
Identify the components used in the Morse Fall Risk Scale.
Identify key points to consider when developing a fall prevention plan (Use the literature to support your decision) Base your initial post on your readings and research of this topic.
. Your initial post must contain a minimum of 250 words. References, citations, and repeating the question do not count towards the 250 word minimum.
In: Nursing
You have the opportunity to buy a stock that just paid a dividend (D0) of $2.00. After doing some research, you have forecasted the following growth rates for the firm’s dividends:
g1 = -40% g2 = 0% g3 = 50% g4 = 25% g5-infinity = 3%
In addition, you estimate that the required return for this stock should be 8%. Show your work.
Hand written or in a word document please
In: Finance
Informing patients of their planned care is part of the informed consent process. Each health care provider needs to provide informed consent prior to providing care.
For this assignment create a fact sheet or infographic about how patient consent is secured.
Provide information on at least two different ways that a patient’s health care rights could be violated in the patient consent process.
Infographics use graphics and color to provide information. You may use free infographics templates found on the internet. Or, use a power point slide to create an infographic. A brochure template from your Word software is another alternative to consider in creating this visual document.
In: Nursing
Unit Assignment Task:
Loans can turn bad and increase banks’ impaired loan position (non-performing loan). The impaired loans would increase credit risk to the detriment of bank insolvency. Discuss this issue complete with thorough analysis of the issue, causes, bank actions and solutions to minimize loss from rising credit risk and bank insolvency.
Marks will be awarded for thorough analysis of issues, causes, bank actions and solutions to minimize impaired loans and bank insolvency. Comprehensive analysis of issues 8 % In-depth discussion of causes with examples 10% Sound discussion of bank actions and solutions 12% Total 30% Word Count : Do not exceed 3,000 Words
In: Accounting
The following financial ratios have been calculated for Nova Ltd for the year ended 30 June 2008: Ratio Actual results Budgeted results Previous year Industry Average Current ratio 1.97 1.92 1.87 1.92 Quick asset ratio 1.06 1.06 1.06 1.11 Inventory turnover 4.21 4.91 4.86 4.76 Net profit ratio 0.05 0.03 0.03 0.03 Gross margin 0.65 0.59 0.61 0.61 Required: Provide four (4) possible explanations for the results of the various ratios for Nova Ltd and explain their implications for the audit. (7marks) (Word Limit: Minimum of 200 words. Maximum 250 of words)
In: Finance
Q32 The manufacturer of a quartz travel alarm clock claims that, on the average, its clocks deviate from perfect time by 30 seconds per month, with a standard deviation of 10 seconds. Engineers from a consumer magazine purchase 40 of the clocks and find that the average clock in the sample deviated from perfect accuracy by 34 seconds in one month. [4 Marks]
(a) If the manufacturer’s claim is correct (i.e., seconds, seconds), what is the probability that the average deviation from perfect accuracy would be 34 seconds or more?
(b) Based on your answer to part (a), speculate on the possibility that the manufacturer’s claim might not be correct.
DO NOT WRITE THE ANSWERS - USE WORD FORMAT.
In: Statistics and Probability
TURN YOUR ANSWER IN WORD.
The ABC Corporation had issued 3% coupon (semi-annual), 5-year, AA-rated bonds to finance its business growth. Use both your financial calculator (write the keys and the answer) and show the function you’d use in Excel).
a. If investors are currently offering $1150, what is the expected YTM on the investment?
i. Is this a premium/discount bond? Describe the relationship of the YTM, the coupon rate and the price of a bond.
b. If they were willing to pay no more than $980 for this bond, what would their expected YTM be?
i. Is this a premium/discount bond?
c. Describe the relationship of the YTM, the coupon rate and the price of a bond.
In: Finance
In: Accounting