C program/Matlab to print the star sequence in reverse

Question 1: Write a C program/Matlab to print the star sequence in reverse order as shown below output. You must use nested for loops. Output: Insert the coding: Question 2: Write a C program/Matlab to print series and find sum of 9+8+7+6+5+4+3+2+1+0 You must use while loops. Insert the coding: Question 3 Write a C program/Matlab to display the following the input should be the number of lines and the output is as shown below. You must use nested while loops. 1 12 1 2 3 1 2 3 4 1 2 3 4 5 Insert the coding

Casino As usual, create a project, class, and write maino

Part A: Casino As usual, create a project, class, and write maino. [Project and class names are your choice. make them descriptive. Therein, do the following: 1. Generate a random number between 1-13 representing card denomination: 1=”Ace”, 2=”2″, 3=”3″. 10- 10″ 11-Jack”12″Queen”, 13=”King’ 2. Generate another random number between 101-104 representing the suit 101=”Hearts, 102=”Diamonds”, 103=”Spades”, 104.’Clubs 3. Print out the numbers and a description of the card as shown in the sample output. Requirements: 1. Write your switch statement to minimize the number of cases. [It can be as few as 4, not counting the default.) 2. Do not include any System.out.println() statements in the if-else or switch statements 3. Use 2 System.out.println( statements 4. Output should be grammatically correct (the article “an” for “Ace” and “8”: “a” for all other denominations) 5. Do not use anything not covered in class yet (loops, arrays, etc.) Sample Output: Denomination: 1 Suit: 102 You picked an Ace of Diamonds Denomination: 2 Suit: 104 You picked a 2 of Clubs Denomination: 2 Suit: 101 You picked a 2 of Hoarts Denomination: 13 Suit: 101 You picked a King of Hearts Denomination: 13 Sult: 101 You picked a King of Hearts Page 103 Part B: Account Creation A person signs up for an account at Acme Explosives (AE) by providing their first and last name, and a password. A username will be generated: the first 5 letters of their last name + the first letter of their first name (lower case) + a random number between 0-99 (e.g., rogersm15). If the person’s last name is shorter than 5 characters, use their entire last name + first letter + random number According to AE policy, a password is valid if it does not contain their first and last name (regardless of case), and is at least 8 characters long. If the password entered is valid, prompt the user to enter their password (again). If they get it right, say “Welcome”, and display their username, otherwise, otherwise printBoom! passwords don’t match. If the passwords is invalid, print out an error message (worded exactly as written in the sample output) Sample Output: Name: Donald Duck Password: quack # too short Nooo! Invalid password (it must be least 8 characters long, and not contain your name) Name: Grace Hopper Password: quackquack Enter password again: quackquack Welcome, hoppeg22 Name: Bugs Bunny Password: itsabugslife # contains “bugs” Nooo! Invalid password (it must be least 8 characters long, and not contain your name) Name: Colonel Chuf Password: ilovewandavision Enter password again: ilovewandavision Welcome, chufc60 # full last name used Name: Colonel Shuffle Fassword: andcant wait forloki Enter password again andcant wait forloki!!! # password miamatah BOTY. passwords don’t match

Write a program that reads the amount of coins collected at the end of each day of a month in a local supermarket and calculates the total amount in fils (1 AED = 100 fils)

1. Count cash: Write a program that reads the amount of coins collected at the end of each day of a month in a local supermarket and calculates the total amount in fils (1 AED = 100 fils). The program reads the data for the entire month from the file coins.txt (assume the month has 30 days). The input file has one line for each day where each line has: number of fils, space, number of 5-fils, space, number of 10-fils, space, number of 25-fils, space, and number of so-fils. Make sure that the total amount is displayed with exactly two decimals. For the sake of testing your program consider an input file where the first 29 lines, each contains 00000 and the last line are 11111. This means the file is for a month where no coins where collected in the first 29 days. The output should be 0.91 AED. Now if you test your program for having 0 0 0 0 0 for the first 28 days and for the last 2 days, we have: 77 117 430 705 520 89 320 414 833 850 Then the answer is shown below: Sample run (with the above file): Total amount collected is: AED 1178.32 execution time: 0.263 s Process returned @ (@xe) Press any key to continue. 2. Data Security Encryption is an effective way to achieve data security. To read an encrypted file, you must have access to a secret key or password that enables you to decrypt it. You are expected to implement a simple encryption/decryption program. The program shall read the text from an input text file character by character (use ein.get() function) and produces an encrypted or decrypted version of the file. Your program shall allow the user to enter either 1 for encryption or 2 for decryption. The encryption procedure is to replace each alphabet by another one and each digit by another digit as follows: character Encrypted character A,B,C……X,Y,Z T, U, V,.., Q, R, S Compute the shift from ‘A’ to ‘T, ‘a’ a, b, c,…….. n, o, p,…,k,l,m to ‘n’, and ‘O’ to ‘s’. Use the % operator to rotate. 0,1,2,……..9 5,6,7…,3,4 Hint Other characters are not encrypted. The decryption procedure is to reverse the encryption procedure such that you obtain the original text file. Sample run: Enter your option: 1. to Encrypt the file 2. to Decrypt the file Option : 1 The encryption result of the input file is stored in “enrypted_msg.txt execution time : 2.634 s Process returned @ (@xe) Press any key to continue. Input file: (available on BB) Sample 1 decrypted_msg.bct — File Edit Format View Help ABCDEFGHIJKLMNOPORSTUVWXYZ abcdefghijklmnopqrstuvwxyz 0123456789 Sample 2 decrypted magtet – Notepad File Edit Format Vew Help His Highness Dr Shaikh Sultan Bin Mohammad Al Qasini, Supreme Council Member and Ruler of Sharjah, attended the opening of the International Conference on Solutions for a better life at the University of Sharjah. The five-day International Conference is being hosted by the University of Sharjah in partnership with west virginia State University of the United States and the world Health Organisation (WHO). Windo In 1.C 100% Windows Of in 1. Coll 0% Output file: (encrypted_msg.txt; this is the input for decrypt process) Sample 1 Sample 2 errypted_msg.be – Notepad D enrypted_msg.txt. N. File Edit Format View Help vf Atuarff we Lunvxu thyena Uva Funzzng Ty Infvzv, File Edit Format View Help Lhcerzr Vbhapvy Frzore naq Khyre bs Lunewnu, TUVWXYZABCDEFGHIJKLMNOPQRS neeragra gur bcravat bs gur Bagreang bany Vbasrerapr nopqrstuvwxyzabcdefghijklm ba Lbyhgvbaf sbe n Urggre Ever ng gur Navirefugl bs Lunewu.Mur svir-nl Bagreang bany Vbasrerar vf 5678901234 orvat ubfgrq ol gur Navirefugl bs Lunewnu va chegarefuve jugu Prfg ovetvavn Lener Navirefvel bs gur Navgrq Lgngrf naq gur Peyq Arnygu Het avfngvba (PAH). Windo Ln 1.C 100% Windows (CF Ln 1, Col1 100% 3. Water Usage Write a program that asks the user to input the total number of available gallons of water (integer). In a loop input the number of gallons you want to use and display the remaining gallons of water. Repeat until the number of gallons as long as there are available gallons of water. At the end, display the number of days taken to finish the gallons of water. Sample run: Enter total available water in gallons: 35 How many gallons do you want to use: 13 The remaining gallons of water – 22 How many gallons do you want to use: 8 The remaining gallons of water = 14 How many gallons do you want to use: 11 The remaining gallons of water = 3 How many gallons do you want to use: 7 Sorry you can only use 3 gallons The remaining gallons of water – water is finished after 4 days

Write a public method in your PieceScooby class called spawn

C) [10 points] Write a public method in your PieceScooby class called spawn with no parameters and returns a NEW PieceScooby with: scooby snacks and canMove properties should have same values as object that this method is being called on (this) • hidden and original properties should be set to false symbol should be set to the symbol of the object that this method is being called on (this) with the value ‘C’ concatenated to the end of it. public PieceScooby spawn()

what property should a graph have that represent or model a job assignment problem

gestion 12 Save Answer 1 points what property should a graph have that represent or model a job assignment problem, if mjobs will be assigned to n people, and not all people are qualified for all jobs if each job should be filled by at least one person and, each person will be assigned to one job only. Justify your answer in detail. For the toolbar, press ALT+F10 (PC) or ALT+FN+F10 (Mac),

code is intended to process a string and count the number of letters of the alphabet, the number of digits, the number of punctuation characters

The following code is intended to process a string and count the number of letters of the
alphabet, the number of digits, the number of punctuation characters, the number of digits, and
the number of spaces/other characters. Does it correctly do that? (Don’t consider any accidental
typos that I may have made.)
int main() {
int numAlpha=0, numDigits=0, numPuncts=0, numOthers=0;
string sent; //a string to hold the user’s sentence
getline(cin,sent);
for (int j=0; j<sent.length(); j++) {
char ch = sent[j];
cout << “Next ch is ” << ch << endl;
if (isalnum(ch))
numAlpha++;
else if (ispunct(ch))
numPuncts++;
else if (isdigit(ch))
numDigits++;
else numOthers++;
} //for
cout << “Number of letters: ” << numAlpha << endl;
cout << “Number of digits: ” << numDigits << endl;
cout << “Number of punctuation characters: ” << numPuncts << endl;
cout << “Number of other characters: ” << numOthers << endl;
return 0;
}
Yes
No

Employee.java Worker.java Manager.java Executive.java package inheritanceemployee; Inheritance – employee

Employee.java Worker.java Manager.java Executive.java package inheritanceemployee; Inheritance – employees Hint: you can use super(parameters) to call the constructor of a superclass. You can use super.methodname() to call a method in a superclass. In Employee.java: Create a public abstract class called Employee. Create class variables ‘name’ and ‘wage’. Implement a constructor public Employee(String name, double wage) which initilises name and wage. Implement accessor methods public String getName() and public double getWage(). Employee.java Worker.java Manager.java Executive.java package inheritanceemployee; Create Class VITODIES Tale al wage. Implement a constructor public Employee(String name, double wage) which initilises name and wage. Implement accessor methods public String getName() and public double getWage(). In Worker.java: Create a public class Worker which extends Employee. Create class variable ‘manager’. Implement a constructor public Worker(String name, double wage, Manager manager) which initilises name, wage, manager. You will need to access the constructor in the Employee class. Implement accessor method public Manager getManager(). Employee.java Worker.java Manager.java Executive.java 1 package inheritanceemployee; Create class variable ‘manager’. 3 import java.util.ArrayList; 5 Implement a constructor public Worker(String name, double wage, Manager manager) which initilises name, wage, manager. You will need to access the constructor in the Employee class. Implement accessor method public Manager getManager(). In Manager.java: Create a public class Manager which extends Employee. Create class variable ‘supervises’, which is type ArrayList. Implement a constructor public Manager(String name, double wage) which initilises name, wage, and sets ‘supervises’ to an empty ArrayList. You will need to access the constructor in the Employee class. Implement public void addSupervisedEmployee Worker employee) which adds the employee to the ‘supervises’ ArrayList. Implement accessor method public ArrayList getSupervises(). Employee.java Worker.java Manager.java Executive.java 1 package inheritanceemployee; 2 3 In Executive.java: Create a public class Executive which extends Employee. Create class variable ‘annualBonus! Implement a constructor public Executive (String name, double wage, double annualBonus) which initilises name, wage, bonus. You will need to access the constructor in the Employee class. Implement accessor method public double getAnnualBonus(). Implement and override) public double getWage() which calculates the fortnightly wage. This is equal to the regular wage, plus 1/52 of the annual bonus. You will need to access the getWage() method in the Employee class. When calculating 1/52 you will need to to think about the data types and what the resulting data type will be.

Coronavirus (Covid-19), many business institutions are forced to switch to remote working

With the current outbreak of the Coronavirus (Covid-19), many business institutions are forced to switch to remote working (i.e. working from home). Private sector is one of the main institutions that are forced to operate online. Such a sudden switch imposes many challenges to all parties (organizations, managers, employees, and customers). Consequently, many changes are taken place to run business as smoothly as possible. Institutions are also required to increase awareness of the Covid-19 and impose measured to control its spread. In the base of this brief overview, answer the following questions: :
1.3 What is an information system? Explain it with using an example of an information system used in the present situation to clarify. (150 words Maximum)

The Triangle represented by three sides Design a class, name it Triangle 1 2 3 Side1 Side2 Side3 1 Triangle(String)

Taski PART 1: Problem Description: The Triangle represented by three sides Design a class, name it Triangle 1 2 3 Side1 Side2 Side3 1 Triangle(String) Data Member Int: represent one of triangle sides Int: represent one of triangle sides Int: represent one of triangle sides Methods Add Constructor : 1. recive a string that represent the sides of the triangle 2. check if the string is able to represent a triangle format as (s1,52,53) 3. split the text to get the values ,values must be positive numbers (if not) throw an exception “Not valid Entries” 4. If the three values are positive values you have to check that the sum of any two sides is larger than the third (if not) : throw an exception “Not triangle” 2 Circumference Read Only property : return siden+side2+side 3 PART 2: Build a simple windows form that 1. Allow the user to insert the sides, the user have to insert values in this format: (51,52,53) and have to be notified if not. For example: (12,2,3): Not Triangle 2. (12,12,2) 3. Split each string that inserted based on the following delimiters:{‘C’,”,”) 4. Each item generated after the split have to be represent a side Form SIDE (S1.52.51) (12.2.2) Circunference Formi smes (51,52,52) Circunference (12,12,2) Not Trangle: Tebe a triangle the sum of wides Must be larger the the thud Circumference 26 CLEAR Forml x SIDES (51,52,53) (12,2) Circumference 26 Not valid Entries OK

Open chat