oblem 1 [5 marks] All vowels (filename: AllVowels.java) Design an algorithm and then write a program...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
oblem 1 [5 marks] All vowels (filename: AllVowels.java) Design an algorithm and then write a program that randomly generates 4 vowels (a, e, i, o, u) all in lowercases. If any time the generated letter is not a vowel, the program re-generates a new letter. The vowels may be repeated. You must use the keyword break or continue in your loop. Problem 1 [5 marks] All vowels (filename: AllVowels.java) Design an algorithm and then write a program that randomly generates 4 vowels (a, e, i, o, u) all in lowercases. If any time the generated letter is not a vowel, the program re-generates a new letter. The vowels may be repeated. You must use the keyword break or continue in your loop. Problem 2 [30 marks] Displaying a calendar (filename: DisplayCalendar.java) Design an algorithm and then write a program that prompts the user to enter a year and the first day of the year, and displays the calendar for the year. For example, if the user enters year 2019, and 2 for Tuesday, January 1, 2019, your program should display the calendar for the 12 months in the year, as follows: Enter a year: 2019 Enter the first day of the year: 2 Sun Mon 6 13 20 27 N N H J 3 10 17 24 7 14 21 28 Sun Mon THHN 4 11 18 85 25 January 2019 Tue Wed Thu 3 10 17 1 8 15 22 29 2 6 N 5 12 19 26 9 16 23 30 February 24 31 Tue Wed Thu 6 13 20 27 2019 7 14 21 N N 28 Fri 4 N P PA 11 18 185 25 Fri 1 H HN 8 15 NG 22 Sat NTC is 5 12 296 19 26 SNOHN Sat 2 9 war 16 23 oblem 1 [5 marks] All vowels (filename: AllVowels.java) Design an algorithm and then write a program that randomly generates 4 vowels (a, e, i, o, u) all in lowercases. If any time the generated letter is not a vowel, the program re-generates a new letter. The vowels may be repeated. You must use the keyword break or continue in your loop. Problem 1 [5 marks] All vowels (filename: AllVowels.java) Design an algorithm and then write a program that randomly generates 4 vowels (a, e, i, o, u) all in lowercases. If any time the generated letter is not a vowel, the program re-generates a new letter. The vowels may be repeated. You must use the keyword break or continue in your loop. Problem 2 [30 marks] Displaying a calendar (filename: DisplayCalendar.java) Design an algorithm and then write a program that prompts the user to enter a year and the first day of the year, and displays the calendar for the year. For example, if the user enters year 2019, and 2 for Tuesday, January 1, 2019, your program should display the calendar for the 12 months in the year, as follows: Enter a year: 2019 Enter the first day of the year: 2 Sun Mon 6 13 20 27 N N H J 3 10 17 24 7 14 21 28 Sun Mon THHN 4 11 18 85 25 January 2019 Tue Wed Thu 3 10 17 1 8 15 22 29 2 6 N 5 12 19 26 9 16 23 30 February 24 31 Tue Wed Thu 6 13 20 27 2019 7 14 21 N N 28 Fri 4 N P PA 11 18 185 25 Fri 1 H HN 8 15 NG 22 Sat NTC is 5 12 296 19 26 SNOHN Sat 2 9 war 16 23
Expert Answer:
Related Book For
Posted Date:
Students also viewed these programming questions
-
a. Example 13-1: Batch Reactor with an Exothermic Reaction Wolfram 1. Adiabatic Case: Use Wolfram to see whether you can find a trajectory that is ready to ignite and whose trajectory looks like a...
-
The Unilever Bangladesh Limited has a plant in Narayanganj, manufacturing Dove shampoo made from the ingredient imported from abroad. The company claims that each bottle of 200ml contain on average...
-
What are articles of incorporation and how do they differ from by-laws of a NFP organization?
-
Warnerwoods Company uses a perpetual inventory system. It entered into the following purchases and sales transactio for March. Units Acquired at Cost Date March 1 March 5 Activities Beginning...
-
What is the process for starting an appeal?
-
Watson Waterbed Works Inc. has an EBIT of $2.75 million, can borrow at 15% interest, and pays combined state and federal income taxes of 40%. It currently has no debt and is capitalized by equity of...
-
Sam's Cat Hotel works 52 weeks out of each year, 6 days of the week, and utilizations a constant audit stock framework. It buys kitty litter for $11.70 per sack. The accompanying data is accessible...
-
Answer the following question. How many U.S. dollars can you buy for C$750 if one Canadian dollar is worth US$0.8168?
-
Question 3: Design CSEStudent class and BBAStudent class which inherit from Student class so that the following code provides the expected output. [Assume, per course tuition fee is 19800. The...
-
. Describe all of the energy types and transformations that occur while you do the event. For example, if you were talking about driving, you would need to connect the burning of gasoline (chemical...
-
All the jumps below are short jumps, meaning that the labels are in the range -128 to +127. IP Code E06C 733F JNC ERROR1 E072 7139 JNO ERROR1 E08C 8ED8 C8: MOV DS,AX ee *** *** *** E0A7 EBE3 JMP C8...
-
1. In your experiment, did the temperature of the gas increase or decrease when moving from a region of high-pressure to low-pressure? How does this relate to the function of an air-conditioner or...
-
where Let A = 7 [ 4 ] Find a formula for Ak, given that A = PDP-, -4 P=[ -1 -2] D = [5 and D 9] 3
-
4. Give the following arrays int a[5] { 1,5,3,4,2); char c[6]={'a','r','r','a', 'y', 's'}; string d[3]={"try", "enjoy", "programming"}; we want to display all arrays by overloading the Display...
-
21. 22. 23. 24. s The Query Wizard will create a simple select query. Simple Find Unmatched Find Duplicates Crosstab Although an attachment is not visible in the table, when you start working with...
-
Recall that Chapter 8 described the binary search algorithm for finding a particular entry in an ordered list. The idea behind binary search is to begin looking in the exact center of the list. If...
-
a. Example 8-1: Trambouze Reactions Wolfram 1. Fix k 2 at 0.015 and then describe how the selectivity varies with k 1 and k 3 . 2. Write a conclusion about your experiments. Polymath 3. What would...
-
The production of ethylene glycol from ethylene chlorohydrin and sodium bicarbonate CH2OHCH2Cl + NaHCO3 (CH2OH)2 + NaCl + CO2 is carried out in a semibatch reactor. A 1.5-molar solution of ethylene...
-
How would you modify Table 6-2 for a. A constant-volume gas-phase reaction, and b. A variable-volume gas-phase reaction? Table 6-2 1. Mole balances: BR dNAdt=rAV dNBdt=rBV dNCdt=rCV dNDdt=rDV PFR PBR...
-
For the sales adjustment transaction class, indicate the three main types of transaction that might occur. For each transaction type, indicate one question that might be used in an internal control...
-
For each of the three functions pertaining to cash receipts transactions, formulate two questions that may be used in preparing an internal control questionnaire for this transaction class.
-
What are some of the inherent risk factors that may affect (1) sales transactions and (2) debtors balances?
Study smarter with the SolutionInn App