Write a Java program using If-Else If That will allow the user to input the age of student and will compute the commission Based on the following criteria: v If Student Age is greater than or equal to 100 then commission = Age * 2% v If Student Age between 70 and 100 then commission = Age *5% v Otherwise, commission =Age*1%
Q: hat will compute the students average • The user will input the following: Name Math …
A: HI, Since the programming language is not mentioned i used python
Q: Write a program that calculates the points earned by a soccer team. The program reads from the user…
A: Dear Student, As no programming language is mentioned I am doing it in c++.
Q: Complete the following program that finds which of the time points comes last. The time is expressea…
A: correct statements are: time1="12:00"time2="00:55"hh1,mm1 = time1.split(":")hh2,mm2 =…
Q: Write a program using if-else statements that convert from lbs to kg and vice versa. The input…
A: Weighting System Weight is the measure of the relative mass a body has or the amount of matter.…
Q: 2. Write a complete program that prompts the user for a test score and prints out the letter score…
A: Given: Write a complete program that prompts the user for a test score and prints out the letter…
Q: In java (eclipse) write a program that inputs an integer. If the integer is greater than 100 or…
A: Required: write a program that inputs an integer. If the integer is greater than 100 or between 50…
Q: A programmer wants to determine whether a score is within 10 points of a given target. For example,…
A: Answer is option D (target-10 ≤ score) AND (score ≤ target +10 )
Q: Write a program that determine the bonus amount using a nested if-else statements . For hourly…
A: As no programming language is mentioned, it is solved using basic C++
Q: Implement the following decision table using a nested if statement and multiple alternatives if…
A: When the grade point average value lies between 1.0-1.99 (inclusive both the values) or not. If yes…
Q: Write a program that calculates the points earned by a soccer team. The program reads from the user…
A: The Java code along with the snapshot of code and output is given below:
Q: Develop a Java program that asks the user to enter a integer number, to determines the temperature.…
A: Code: import java.util.Scanner;public class Main{ public static void main(String[] args) { int…
Q: Write a java program that computes the total tuition fee of the student based on the given mode of…
A: I have provided JAVA CODE along with CODE SCREENSHOT and also provided TWO OUTPUT…
Q: Write the java code to take the employee Net Salary as input and according the below…
A: Here you need to definitely check a condition but you are not supposed to use if-statements. We need…
Q: Write a program to calculate the electricity bill. The rates of electricity per unit are as follow:…
A: PROGRAM CODE: #include <iostream> // include header file for input output…
Q: Write a program that computes the cost of painting and installing carpet in a room. Assume that the…
A: In this question, we will create a class ROOM to store the properties of the room and to calculate…
Q: A contractor orders, say, 30 cubic yards of premixed concrete to construct a patio that is to be,…
A: C++ Code for the given Question #include<bits/stdc++.h>#include <iostream> using…
Q: Create a Sample Code using Java If Else Statement Problem Here's the given: If - Good Morning else…
A: I have given java code below
Q: Jacob is a retailer for ice. Normally a bag of ice costs $2.5, but the price varies with the amount…
A: import java.util.*;public class Main{ public static void main(String[] args) { Scanner sc = new…
Q: Write a program that determine the bonus amount using a nested if-else statements . For hourly…
A: Start Input type If employee is hourly based Input working hours If hours more than 40, bonus is…
Q: Java Write a program that keeps track of an employee’s hours for a work week and then computes the…
A: The Answer is
Q: Write each condition down below in valid Java boolean expressions x > y > z X and y are both less…
A: Java boolean expressions: The Java operators are different from the mathematical symbols like =, ≠,…
Q: Write a program that inputs an integer. If the integer is greater than 100 or between 50 and 75…
A: task: create a program that inputs an integer. If the integer is greater than 100 or between 50 and…
Q: Write the statement in words if: p: Firemen work hard. q: Firemen wear red suspenders 3) ~p → q
A: Please refer to the following step for the complete solution of the problem above.
Q: Write a program that specifies whether a given number (x) falls in one of the following categories…
A: Description: Note: Since you have not provided the language to write the code so I am using java…
Q: Write a program to play the following simple game. The player starts with $100. On each turn a coin…
A: Question Write a program to play the following simple game. The player starts with $100. On each…
Q: Java: How can I get a users input for an interval? For example: Enter an interval [x,y]: and then…
A: import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sr…
Q: Write a program that uses an if-elif-else statement to determine a traveling schedule. 1) request…
A: 'date'print ("Enter the your_date between(1-31).")date = int(input())if (date<1): print…
Q: reate a JAVA program that prompts the user to enter a numerical test mark and displays the…
A: Here I have taken input from the user and then used the if-else block to first validate it. Then, I…
Q: Write a program which takes fuel type from user. If fuel type in not in the range of 1 to 3 then it…
A: Note: The given Program is in C++ programming language
Q: The validity bit of a sequence of bits is O if the number of 1's in the sequence is even and 1…
A: PROGRAM CODE: import java.util.Scanner; // import the scanner class of…
Q: Ask the user to enter a day of the week in 3 letters. * Respond with the meal plan for that day.…
A: PROGRAM: //Header file import java.util.Scanner; //Defining the class class WeeklyMeakPlan {…
Q: Program33.java Write a program that generates a random Fahrenheit oral temperature between 92 and…
A: To generate a random number, Random class is used in java util library. nextInt(bound) method…
Q: Write a JAVA program that asks the user to input the instructor Salary (double) and Academic Rank…
A: Code: import java.util.*; class Main { public static void main(String args[]) {…
Q: Write a program that can accept two inputs - a food type and a price, and determines if the food is…
A: Python used to answer this question
Q: A company selling household appliances gives commissions to its salesman determined by the kind of…
A: import java.util.*; class GFG { public static void main (String[] args) { Scanner sc= new…
Q: ACTIVITY Write an if-else statement with multiple branches. If year is 2101 or later, print "Distant…
A: Answer is given below .
Q: Using proper java syntax write the following, using an if condition. if x = y and z = m then add 1…
A: Code using proper java syntax: if (x == y && z == m){ a=a+1;}
Q: Write a C++ program that : You have to do the following question only by nested if-statement. FROM…
A: Write a C++ program that : FROM GRADE A TO F A 93-100% A- 90-92% B+ 87-89% B 83-86% B- 80-82%…
Q: Given four positive integers a, b, c, and d, compute the sum of those among them that are odd.…
A: A Java program that computes the sum of those among the given integers that are odd without using…
Q: write a program in which ask from a user to enter name and id and show there as well. then ask again…
A: Since no programming language is mentioned, I will attempt this in python. if you need it in a…
Q: Write a Java program that willl read letters Coded A to Z(Uppercase ajd lowercase depending on the…
A: Below is the required JAVA program: - Program Approach: Importing the package. Defining the…
Q: CHALLENGE ACTIVITY 4.4.5: Multi-branch if-else statements: Print century. Write an if-else…
A: I have given python solution below.
Q: Write a program that calculates the points earned by a soccer team. The program reads from the user…
A: Code explained in comments:
Q: Write a program that computes how much a customer has to pay after purchasing two items. Make the…
A: Step 1 : Start Step 2 : Take user input for the price of Item 1 and item 2. Step 3 : Calculate the…
Q: Create a program and inside your program, type the code as given below. Then rewrite the nested ifs…
A: Hey, since there are multiple questions posted, we will answer first question. If you want any…
Q: Write a program that reads the temperature and unit from the user and prints a message indicating if…
A: In C Programming, When an if else statement is present inside the body of another “if” or “else”…
Q: Write a C-language program using ladderized if-else statements, that will compute for the discount…
A: Control structures are used to determine the path of execution and control the execution of…
Q: A contractor orders, say, 30 cubic yards of premixed concrete to construct a patio that is to be,…
A: Given The answer is given below.
Q: Write the statement in words if: p: Firemen work hard. q: Firemen wear red suspenders. 1) ~q 2) p…
A: Tilde sign is used for negation which represents negation of a sentence. ∧ logic combines two or…
Step by step
Solved in 4 steps with 1 images
- Write a program that reads student scores, gets the best score, andthen assigns grades based on the following scheme:Grade is A if score is ≥ best -5Grade is B if score is ≥best -10;Grade is C if score is ≥best -15;Grade is D if score is ≥best -20;Grade is F otherwise.The program prompts the user to enter the total number of students, and thenprompts the user to enter all of the scores, and concludes by displaying the grades.Here is a sample run: Enter the number of students: 4 ↵EnterEnter 4 scores: 40 55 70 58 ↵EnterStudent 0 score is 40 and grade is FStudent 1 score is 55 and grade is CStudent 2 score is 70 and grade is AStudent 3 score is 58 and grade is CAn internet service provider has three different subscription packages for its customers: Package A: for RM9.95 per month 10 hours of access are provided. Additional hours are RM2.00 per hour. Package B: for RM13.95 per month 20 hours of access are provided. Additional hours are RM 1.00 per hour Package C: for RM 19.95 per month unlimited access is provided. Write a JAVA program using if/else or switch selection to calculates a customer’s monthly bill. It should ask the user to enter the letter of the package the customer has purchased (A, B, or C) and the number of hours that were used. It should then display the total charges.Use java code Body Mass Index (BMI) is a measure of health on weight. It can be calculated by taking your weight in kilograms and dividing by the square of your height in meters. The interpretation of BMI for people 16 years or older is as follows: BMI below 16 16-18 19-24 25-29 30-35 above 35 Interpretation seriously underweight underweight normal weight overweight seriously overweight gravely overweight Write a Java program that prompts the user to enter a weight in kilograms and height in meter and display the BMI. Use nested if- else statements to solve this exercise. Here is a sample run: Enter weight in kilograms: 66.22 Enter height in meters: 1.788 Your BMI is 20.71353142 You are normal weight
- A Software Engineering Company has a salary system based on position level. The table below represents the salary paid according to each position: Employee Position Employees Salary Employees' Name: Ali Position: Bonus Amount: Final Cost: $3500 Manager Supervisors Sales Person The Company decided to give a 25% bonus for employees whose salaries are less than 3000$ due to holidays. Write a java program that asks the user to enter his/her name, and his/her work position. The program should calculate and display the total salary of the employee based on his/her salary position, the bonus amount and the final salary for an employee. Make sure that your program outputs exactly as the sample run below. Sample Run1: Enter Your Name: Ali Enter Your Position (M for Managers, S for Supervisors or P for Sales Person): M Fixed Monthly Salary 3500$ 2100$ Manager Salary: $3500.0 $0.0 Internet Service Bill 700$ Sample Run2: Enter Your Name: Cerine Enter Your Position (M for Managers, S for…Write Java program to allow the user to input his/her age. Then the program will show if the person is eligible to have a driving license, to vote or both. A person can have a driving license if he is over 18 years old. A person who is eligible to vote must be older than or equal to 21 years old. Sample run1: Enter your age: 18 You are eligible to vote. Sample run2: Enter your age: 22 You can get a driving license. You are eligible to vote.Write a program that computes how much a customer has to pay after purchasing two items. Make the lower-priced item half price. If the two items have identical prices, you can make one or the other half price. The price is calculated according to the following rules:• Buy one get one half off promotion: the lower price item is half price.• If the customer is club card member, additional 10% off.• Tax is added. Inputs to the program include:• Two items’ prices• Have club card or not (User enters ‘Y’ or ‘y’ for “yes”; ‘N’ or ‘n’ for “no”)• Tax rate (User enters the percentage as a number; for example, they enter8.25 if the tax rate is 8.25%) Program displays:• Base price - the price before the discounts and taxes• Price after discounts - the price after the buy one get one half off promotionand the member’s discount, if applicable• Total price – the amount of money the customer has to pay (after tax)printed with the precision of 2 decimal digits. Hint: In order to print a number in a…
- white a java program that calculate commission. The salespeople receive $200 per week plus 10% of their weekly gross sales (for that week). If Matt grosses $3,000 in a week he receives $200 plus 10% of $3,000 for a total of $500. Write a program that determines how many of the salespeople earned salaries in each of the following ranges: 1. $200 - 299 2. $300 - 399 3. $400 - 499 4. $500 - 599 5. $600 - 699 6. $700 - 799 7. $800 - 899 8. $900 - 999 9. $1,000 and over Please assume that each salesperson's salary is truncated to an integer amount.For an invoice calculation program, write the JAVa program that calculates the amount of VAT and the price of goods or services excluding VAT, according to the VAT rate and the total amount including VAT entered on the keyboard. (Total amount including VAT = cost of goods services excluding VAT X VAT rate + price of goods services excluding VAT)Write a program that reads student scores, gets the best score, and hence assigns grades based on the following scheme: Grade is A if score is > = best - 10; Grade is B if score is > = best - 20; Grade is C if score is > = best - 30; Grade is D if score is > = best - 40; Grade is F otherwise. The program prompts the user to enter the total number of students, then prompts the user to enter all of the scores, and concludes by displaying the grades. Language: C++
- Using Java Language use Nested IF PAYROLL SYSTEM Write a program that would compute the salary of an employee based on the information indicated on thetable given below. The program should ask the user to enter employee name, status code, departmentcode, position code, and number of hours worked. Then compute for the gross income of the employeeby multiplying the number of hours worked into his rate per hour based on the employee’s position identifiedin each department. Then compute for the total deductions by adding the percentage from BIR and Securitytaxes based on his civil status. Finally, compute for the net income by subtracting the total deductions fromthe gross income.Using Do-while Loop in Java Write a program that let the user include his or her three (3) grades. After inputting the three (3) grades, the program should compute and print the average. After printing the average, it should determine whether: If average score is equal or greater than 90, the program will print "A" If average score is greater than or equal to 70, and less than 90, the program will print "B" If average score is greater than or equal to 50, and less than 70, the program will print "C" If average score less than 50, the program will print "F"Using Paython Write a program that asks a student for his grade (out of 100) in 3 exams and then print out his final grade (out of 100), given that the weight of the first exam is 30%, the second 30%, and the third 40%.Example Input:Exam1: 70Exam2: 80Exam3: 90Example Output:Total Grade = 81Explanation: 0.3 * 70 + 0.3 * 80 + 0.4 * 90 = 81