Write a program in java to check whether a person is eligible for marry or not. Consider for men the age will be 21 and for women the age will be 18 and you have to take different conditions
Q: Write a Java program that calculates and prints the monthly pay for an employee. The net pay is…
A: Actually, program is an executable software that runs on a computer.
Q: Write a JAVA program to get the value in poise after taking the value in poiseuille form
A: The Poiseuille's formula finds the disharged streamlined volume flow through a smooth-walled…
Q: Write a Java program for a Play-House Manager, who would like to calculate the total profit from…
A: Here is java code to implement above problem.
Q: Write a program in java to compute the population of current year,if the population of current year…
A: Program approach - Declare the class. Define the main method. Declare the variables needed for the…
Q: Write a JAVA program, to check whether a given number is positive number or negative number
A: Please find the answer below :
Q: 6. Write a Java program that reads the length of a scale in inches and then prints the equivalent…
A: Write a Java program that reads the length of a scale in inches and then prints the equivalent…
Q: Write a Java program that calculates the size of equal pieces in a puzzle board. You are asked to…
A: Required:
Q: Write a java program to calculate the electricity bill for a customer , The program should get the…
A: ALGORITHM:- 1. Take input details from the user. 2. Calculate the units consumed on the basis of…
Q: Write a Java program that asks a user to enter the three angles of a triangle. If the sum of three…
A: import java.util.Scanner; class Main { publicstaticvoid main(String[] args) { Scanner sc = new…
Q: Write a program in java to find the remainder when the first number is divided by second number…
A: Given:
Q: Write a program in java to find the hours, minutes and seconds from the given seconds. You should…
A: Required:- Approach:- formula used for seconds = Total seconds % 60 for minutes = (Total seconds…
Q: Write a Java program to take a string, print true if the string starts with "hi" and print false…
A: Introduction: Here we are required to create a JAVA program that checks whether a string starts with…
Q: rite a java program to Check Whether a Number is Positive or Negative.
A: Introduction: Write a java program to Check Whether a Number is Positive or Negative.
Q: Create a program using java language that will calculate the average of 4 given grades shown as an…
A: Code public class Main{ public static void main(String[] args) { int…
Q: Write a Java program that can read a commodity code, quantity of the commodities bought and the unit…
A: public class Tester{ public static void main(String[] args) { String commodity; int quantity;…
Q: Write a program with java that finds the total fuel cost of the vehicle according to the amount of…
A: java program in which user has to input amount of fuel spent per km : price per liter of fuel :…
Q: Write a java program to find the distance travelled by a car by taking the speed and time
A: As given, I need to write a Java program that takes speed and time as input and find distance. The…
Q: Write a complete Java program that asks the user to input the radius (r) and the height (h) of a…
A: Please find the answer below :
Q: Write Java code to repeatedly print each single digit from 9 down to 1 the number of times based…
A: Step 1 : create a driver function Step 2 : create a loop int i = 9 till i >= 1; i-- Step 3 :…
Q: Write a java program to find the third angle of a triangle after taking two angles from user.
A: GIVEN:
Q: Write a Java program that calculates the average student's score and percentage
A: Required: Write a Java program that calculates the average student's score and percentage
Q: Write a Java program that determines whether a number n given by the user is outside the range ]a,…
A: Algorithm : Step 1 : create object of Scanner class. Step 2 : ask for the value of a. Step 3 : ask…
Q: In java Write a program to take user input for principal, rate and time and find the simple…
A: Requirements :- In java Write a program to take user input for principal, rate and time and find…
Q: Write a program in java to find the semi perimeter of rectangle and take breadth and length from use
A: perimeter of rectangle is 2(l+b) semi perimeter of rectangle is half of perimeter that is (l+b)…
Q: Write a java program that ask the user to enter number of days in the month, then reads the daily…
A: logic:- read value of n iterate from I=0 to I<n Read values in array arr. end loop set…
Q: Write a java program to find the depreciation using the amount = 1000 and rate = -7 and year is 5
A: 1) Below is JAVA program to calculate depreciation of amount 1000 after 5 years at rate of -7…
Q: Write a java program to find the values of X, Y and Z[1,10] that satisfy the following equation:…
A:
Q: Write a Java program to get the mobility after taking magnitude of drift velocity per unit electric…
A: Required:- Write a Java program to get the mobility after taking the magnitude of drift velocity per…
Q: Write the java program for the following problem. The program will accept the values of the radius…
A: Given: To write a java program to calculate volume of code and cylinder for given following…
Q: Write a program in java to get the number from user and then check whether all digits in that number…
A: Required:- Please see the code below with the output.
Q: 34. In JAVA language, write a program to input the distance in kilometers and then convert the…
A: Given: To write a java program to input distance in kilometers and then convert the distance in…
Q: Write a Java program that reads the weight in pounds and convert the weight into Kilograms. The…
A: import java.util.Scanner; public class Pounds_to_Kilograms { public static void main(String[]…
Q: Write a java program that will find spacial character and alphabet from input and also find out the
A: Solution :
Q: use java to a program that displays all the leap years, eight per line, from 101 to 2500, separated…
A: Please find the answer below
Q: Write a program in java in which you have take standard from a student and print if he had to give…
A: Requirements :- Write a program in java in which you have take standard from a student and print if…
Q: Write a program in Java that will compute the average grade of three (3) quizzes.
A: Given: TO write a java program that will compute the average grade of three quizzes.
Q: Write a java program to give the example for this operator. And also use the 'this' keyword as retur…
A: Note: This code should be rewritten instead of copying to the compiler otherwise it will throw a…
Q: Write a JAVA program to read input the age (in years) and weight (in kg) from the user and check if…
A: Write a JAVA program to read input the age (in years) and weight (in kg) from the user and check if…
Q: print numbers reversed from 1 to 100.
A: Here, the static recursive method named reverse displays the reverse of a number. In the main method…
Q: Write a JAVA program in which an employee enters his/her age(in years) and the program tells whether…
A: Write a JAVA program in which an employee enters his/her age(in years) and the program tells whether…
Q: Write a java program that find the Fibonacci series up to a given number of iterations that entered…
A: To write java program to find Fibonacci series.
Q: Write a Java program that displays the prime numbers between A and B
A: Program: import java.util.*; public class Main { public static void main(String[] args) {…
Q: Write a java program that accepts two double variables and test if both strictly between 0 and 1 and…
A: code : - // import Scanner class by this moduleimport java.util.*; public class Main{ public static…
Q: Write a Java program that asks the user to input the jackets quality in any letter case (HQL for…
A: Find Your Code Below
Q: Write a Java program that prompt user to input 10 students in a class. Then, prompt user to input…
A: The code given here is
Q: Write a Java program that generates a random number between 50 and 150 that repre temperature in…
A: - We need to code the bean boiling problem in java.
Q: Write a java program to find the batting average of user taken total runs, user inputted number of…
A: start input total runs , number of innings , notout calculate batting average…
Q: Write a java program to get the commission on a product if you take the 15% commission. You have to…
A: Required:- Write a java program to get the commission on a product if you take the 15% commission.…
Q: Write a program in Java that will convert the measurement from yards to meters.
A: logic:- 1 yard=0.9144 meter. read value of yard. Multiply yard value by 0.9144 display result i.e…
Q: Create a Java program that shows Pass by value and pass by reference.
A: Pass by value: In call by value, when we call a function, the values of actual parameters are passed…
Write a
Trending now
This is a popular solution!
Step by step
Solved in 4 steps with 2 images
- Write a program code in Java Write a program to compute the ideal weight for both males and females. According to one study, the ideal weight for a female is 100 pounds plus 5 pounds for each inch in height over 5 feet. For example, the ideal weight for a female who is 5'3" would be 100 + 15 = 115 pounds. For a male the ideal weight is 106 pounds plus 6 pounds for each inch in height over 5 feet. For example, the ideal weight for a male who is 6'2" would be 106 + 14*6 = 190 pounds. Your program should ask the user to enter his/her height in feet and inches (both as integers -- so a person 5'3" would enter the 5 and the 3). It should then compute and print both the ideal weight for a female and the ideal weight for a male. The general outline of your main function would be as follows: Declare your variables (think about what variables you need -- you need to input two pieces of information (what?), then you need some variables for your calculations (see the following steps) Get the…Welcome to the era of Aladdin and the great magic lamp. This is 1st of January and Aladdin will be in jail for one year. He was recently caught for helping forty thieves. Now he has nothing to do. But he knows that Jasmine is waiting for him. At some point he got an idea to give Jasmine a magical program that can find intervals of months from a year. This allows her to easily determine how long it will take for Aladdin to get out. Then Aladdin rubs the magic lamp and The Genie appears. Then he asked The Genie to make such a magical program. Unfortunately the Genie doesn't know programming and he wants your help to create that magical program. Genie will give you N as the day of the year and you have to print in which month that day is. Input Format Input will contain one line with a single integer N, day of the year. Constraints 1 <= N <= 365 Output Format Print a single line containing the name of month. Be careful about the newline ('\n') at the end. Sample Input 0 1 Sample…Write a program In Java OOP language A house has 20 members and 20 loafs. A man can eat 3 loafs, women can eat 2 loafs, and child can have only ½ loaf. Each day the 20 loafs are distributed evenly among the members. How many men, women, and kids are in the house?
- in C# Sometimes figuring letter grades is hard. Write a program that asks for, and reads from the user, a midterm exam grade and a final exam grade. Compute the average of those two grades and ouput a letter grade based on the scale shown below. CHALLENGE PROBLEM: One of my graduate school classes modified the above calculation. This professor said that the final grade would be determined by the simple average of the midterm and the final, however, if the student scored better on the final than they did on the midterm, the professor would weight the midterm exam at 25%, and the final exam at 75% when computing the final grade. Modify your code to use this professors modification in determining letter grade. Here is the grading scale:MBG students want to change the genetics of plants in AGU. The new plant has a different growing sequence. It grows t cm each day, but every night it loses its height by k cm. While they were discussing that new interesting model, they wanted to formalize the growing algorithm. You should help the student calculate how many days are needed for the plant to grow m cm. Your program on java will take 3 integer values, t, k, and m, respectively. One line output will be showing the number of days. Sample Input: 4 1 5 Sample Output: 2Control structures: In Java only please. Output the position of the largest number and the largest number in the squence a0, a1, a2....ak. For example, the largest number of the squence is 75, 226, 113, 340, 170, 85, 256, 128, 64, 32, 16, 8, 4, 2, 1 is 340, and it's position is 4. Test your program for the following values of x: 75, 111, 678, 732, 873, 2048, and 65535. Thank you
- ISP-Java Write a program whose input is two integers, and whose output is the first integer and subsequent increments of 10 as long as the value is less than or equal to the second integer. For coding simplicity, output a space after every integer, including the last. Ex: If the input is: -15 30 the output is: -15 -5 5 15 25 Ex: If the second integer is less than the first as in: 20 5 the output is: Second integer can't be less than the first.Write a program in any programming language to caleulate and print the Electricity bill of a given customer. The unit consumed by the user should be taken from the keyboard and display the total amount to pay to the customer. The charge are as follow : Unit Charge/unit upto 199 @1.20 200 and above but less than 400 @1.50 400 and above but less than 600 @1.80 600 and above @2.00 If bill exceeds tk 400 then a surcharge of 15% will be charged and the minimum bill should be of tk 100/- Sample input: 800 Sample output: unit Consumed :800 Amount Charges @tk 2.00 per unit : 1600.00 Surcharge Amount : 240.00 Net Amount Paid By the Customer : 1840.00Write a java program that determines a student’s grade. The program will accept 3 scores and computes the average score. Determine the grade based on the following rules: - If the average score is equal or greater than 90, the grade is A. - If the average score is greater than or equal to 70 and less than 90, the grade is B. - If the average score is greater than or equal to 50 and less than 70, the grade is C. - If the average score is less than 50, the grade is F.
- Write a JAVA program in which an employee enters his/her age(in years) and the program tells whether he/she satisfies the minimum age criteria for promotion. Given: Minimum age required for promotion is 28 years.Write a C program for a match-stick game between the computer and a user. Your program should ensure that the computer always wins. Rules for the game are as follows: • There are 21 match-sticks. • The computer asks the player to pick 1, 2, 3, or 4 match sticks. • After the person picks, the computer does its picking. • Whoever is forced to pick up the last match-stick loses the game.Write a program that plays a dice game called "21" It is a variation on BlackJack where one player plays against the computer trying to get 21 or as close to 21 without going over. Here are the rules of the game: You will play with dice that have numbers from 1 to 11. To win, the player or the computer has to get to 21, or as close as possible without going over. If the player or computer goes over 21, they instantly lose. If there is a tie, the computer wins. Starting the game: The player is asked to give the computer a name. For now, we'll simply call the computer opponent, "computer." The game starts with rolling four dice. The first two dice are for the player. These two dice are added up and the total outputted to the screen. The other two dice are for the computer. Likewise, their total is outputted to the screen. Player: If a total of 21 has been reached by either the player or the computer, the game instantly stops and the winner is declared. Otherwise,…