Write a program that reads the value of x and y, then if x is bigger than or equal y calculate and print the value of z according to z = x8 + 5Cos y 23y6 %# else, calculate the following: Z = 20 + x + x2 + cos 1
Q: Write a program that asks the user to enter n and then it computes the value of the sum: 12 + 22+32…
A: #include <iostream> using namespace std; int main(){ long long n; cout<<"Enter…
Q: Write a program that reads in the radius of a circle as an integer and prints the circle's diameter,…
A: Actually, program is a executable software that runs on a computer.
Q: A program for entering a number. If 2 points the number is greater than 100, it prints the number,…
A: Ans-: 1) option (a) 2) false 3) option (a)
Q: A driver will be fined P500 if his speed goes beyond 80 kph and P800 if it goes beyond 100 kph. Make…
A: // FINE: #include<bits/stdc++.h>using namespace std;int main(){ float speed;…
Q: Write a program to calculate and display ticket price. using python The flight ticket price…
A: ALGORITHM:- 1. Take input from the user for all the variables. 2. Calculate the cost of the ticket…
Q: Write a program that converts numbers to words. For example, 895 results in "eight nine five."
A: Below is the required C++ code. Program Approach: Include necessary header files and use a…
Q: Write a program that reads an integer and checks whether the number is odd or even. You should use…
A: #include<iostream> using namespace std; int main(){ int n; cout << "Enter a…
Q: Write a program that reads a code and temperature. If the co Fahrenheit. If the code is 2, convert…
A: Fortran 90 program: Program Hello IMPLICIT NONE !declaration REAL::temperature,…
Q: Write a program that asks the user to enter a month (1 for January, 2 for February, etc.) and then…
A: Program plan: This software asks the user to enter any number from 1 to12, with 1= January, 2=…
Q: Write a python program to check number of digits in a number, if number is between 0-9 then print…
A: PROGRAM CODE: number = int(input("Enter a number: "))if(number >= 0 and number <= 9):…
Q: Write a program using integers user_num and x as input, and output user_num divided by x three times…
A: The Answer is in Below Steps
Q: Write a python program to check number of digits in a number, if number is between 0-9 then print…
A: Actually, python is a easiest programming language. It a is a dynamically typed programming…
Q: Suppose you deposit $50 in a bank account every month for a year. Every month after the deposit has…
A: I give the code in Matlab as per your requirement along with output and code screenshot
Q: Write a program that calculates the electricity bill. The rates of electricity per unit are as…
A: Introduction of program In this program, we will give input on Electricity Unit Consumed. Charges…
Q: Write a program that calculates the number of hours, minutes, and seconds in N seconds. Example: In…
A: The above question is solved in step 2 :-
Q: python Write a program that takes in a line of text as input, and outputs that line of text in…
A: Step 1:- Given:- Takes in a line of text as input, and outputs that line of text in reverse. The…
Q: Write a program that asks the user to enter a month (1 for January, 2 for February, etc.) and then…
A: Code: #include <iostream> using namespace std;//here is the main functionint main(){ //here…
Q: Write a program that prompts the user to enter an integer and prints the value of the following…
A: Below I have provided Java Programming. Also, I have attached the screenshot of the code and output…
Q: Write a program that asks the user for a number, and multiplies it by 3 then prints out the result:…
A: Start Prompt the user for input Parse it as integer Multiply the number by 3 Print the result Stop
Q: In Python write a program that demonstrates the scenario below: An employee’s total weekly pay…
A: We need to provide a python program to employee’s total weekly pay. Where, total week pay= regular…
Q: Write a program that asks the user for two integers that will correspond to the numbering of the…
A:
Q: write a program that asks a user for a number of digits of precision, and prints the value 2/7…
A: import mathn=int(input("Please enter the number of digits of precision for 2/7 :"))print('The value…
Q: Write a program named FahrenheitToCelsius that accepts a temperature in Fahrenheit from a user and…
A: using System; namespace Celsius{ class Program { static void Main(string[] args)…
Q: Write a program that asks the user for a number and prints out 100 divided by the number: Enter a…
A:
Q: Write a program that asks the user for a number and prints out the number cubed (raised to the power…
A: Lets see the solution.
Q: Write a program to find the Celsius value when Fahrenheit value reaches above 98.6 (Human body…
A: logic: - Input fahrenheit value and store it in variable F write celsius=(F-32)*5/9 display F value…
Q: Write a program that prompts the user to input three (3) integers: MM, DD, and YYYY. For example, 07…
A: Introduction: Here we are required to create a program that tells us the difference between the 1st…
Q: Write a program that prompts the user to enter the three points (x1, y1), (x2, y2), and (x3, y3) of…
A: Python Code: # Enter three points for a trianglex1, y1, x2, y2, x3, y3 = eval(input( "Enter three…
Q: In Python: Write a program using integers user_num and x as input, and output user_num divided by x…
A: Program: #main function if __name__ == '__main__': #get user inputs user_num, x =…
Q: Write a Python program that asks user for an amount inCanadian dollars and prints the amount in US…
A: Based on python
Q: Write a program that asks the user for a number and prints out 2 to the power of that number: Enter…
A: Given Python program to find 2^n.
Q: Write a program that asks the user for a number then prints out that number with the message shown:…
A: Code to print the message as per output #include <iostream> using namespace std; int main() {…
Q: Write a program that prompts the user to enter a three-digit integer and determines whether it is a…
A:
Q: Write a program that accepts a number and determines whether the number is positive, negative or a…
A: Given:
Q: Write a program that prompts the user to input three (3) integers: MM, DD, and YYYY. For example, 07…
A: python program to number of days elapsed from 01 January of that year
Q: Write a program that will ask the user to enter an integer number and display the message r even…
A: An even number is a 2-fold integer. An integer not precisely divided by 2 is a mysterious number.…
Q: Write a program that will help you to learn multiplication. The program prompts the user to enter…
A: As there is no programming language mentioned in this question so program is attempted in c++…
Q: Write a program named FahrenheltToCelsius that accepts a temperature in Fahrenheit from a user and…
A: Please find the answer below :
Q: • Write a program that asks the user for a number n and prints the sum of the numbers 1 ton. By used…
A: <!DOCTYPE html><html><body><script>//asking user to enter valuevar…
Q: Write a program that reads an integer and prints how many digits it has by checking whether the…
A: NOTE Below is the program for the given question. Hope you understand it well. If you have any…
Q: Java code for this: Given two number for the variables A and B, create a program that would: A.…
A: Write a program using java that will follow the following conditions and given output: Given two…
Q: Write a program using integers userNum and x as input, and output userNum divided by x four times.…
A: Code: user_num = int(input())x = int(input()) for i in range(3): user_num = user_num // x…
Q: Write a program that will compute the sales tax on a $352 purchase. Assume the state sales tax is…
A:
Q: Write a computer program to read x, y and z, and then compute Taccording to the following equations:…
A: As no programming language is mentioned, it is solved using basic C++
Q: Write a program that calculates the potential energy of 3 charges q1 = 1, q2 = 2, 43 = 3 located at…
A: please do upvote for my efforts thanks! answer: CODE #include…
Q: Write a program that accepts a number and determines whether the number is positive, negative or a…
A: Given: To write a C code.
Q: Write a program that calculates and prints the volume of a pyramid given the base (b) and the height…
A: Note: Below is the required program in the C++ language. Program Approach: Defining the necessary…
Q: Write a program that calculates the attendance percentage for students, there are total 120 working…
A: Note: In this question the coding language is not specified then we are doing this question in the…
Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 1 images
- Write a program that reads the employee's name and base salary and then calculates the tax and net amount Salary where: Net salary = Basic salary If the basic salary is less than 500 (no tax) Net salary = basic salary - tax value So that the tax amount is 5% of the basic salary Then it prints the employee's name and net salary %3D 2:40 PM /Write a program that calculates the potential energy of 3 charges q1 = 1, q2 = 2, q3 = 3 located at points (1,2, 3), (3, –4, –5), and (-4, 2, –6) respectively. The units are coulombs for charge and meters for coordinates. The energy is given by the expression 9293 9193 9142 + T12 U = k r23 T13 where is the distance between the charges q; and q;, and k = 9 × 10º in SI units. Tij Your program should print the result on the screen.Write a program that will display a table of trigonometric functions: sin x, and tan x for x is from 0 to 20 degrees. The output should be: COS X, Angle in degrees sin x COS X tan x 1 1 0.0175 0.9998 0.0175 0.0349 0.9994 0.0349 20 0.3420 0.9397 0.3640 2.
- Write a program to calculate the position of a projectile at a given time t. For an initial velocity vo and angle of departure ®g, the position is given by x and y coordinates as follows (note: the gravity constant g is 9.81 m/s²): X= V0 Cos (0)t y=vo sin (8,)t –; gt The program should initialize the variables for the initial velocity, time, and angle of departure. It should then call a function to find the x and y coordinates, and then another function to print the resultsWrite a program that calculates and prints the volume of a pyramid given the base (b) and the height (h) of the pyramid. The formula to calculate the volume is: Volume = (1/3) *b * h Enter the base of the pyramid: 3 Enter the height of the pyramid: 2 The volume is 1.9998Write a program that calculates the number of hours, minutes, and seconds in N seconds.Example: In 3601 it is equal to 1 hour 0 minutes 1 second
- One way to determine how healthy a person is by measuring the body fat of the person. The formulas to determine the body fat for female and male are as follows: Body fat formula for women: A1=(body weight*0.732)+8.987 A2=wrist measurement(at fullest point)/3.14053 A3=waist measurement(at navel)*0.15753 A4=hip measurement(at fullest point)*0.24953 A5=forearm measurement(at fullest point)*0.434 B=A1+A2-A3-A4+A5 Body fat=body weight-BWrite a program that generates a random integer N between 0 and 20 (included). Then it will ask the user continuously to enter a value V between O and 20. • If the V is equal to N the program displays "you win!!" and ends • If the difference between V and N is equal or greater than 12 the program dispiays "Very Cold" • If the difference between V and N is less than 12 and equal or greater than 6 the program displays "Cold" • If the difference between V and N is less than 6 and equal or greater than 3 the program displays "Hot" • if the difference between V and N is less than 3 the program displays "Very hot" The program ends if the user guess the correct number or if he enters 10 wrong numbers. If the user enters 10 wrong numbers the program displays "You lost" and the correct number. Hint: To compute the difference between V and N use Math.abs(V-N) Using java Runi Enter a number between 0 and 20:5 Very hot Enter a number between 0 and 20: 10 Run2 Enter a number between O and 20: 15…Write a program that will read value of the radius to compute the Area and Perimeter of a Circle. Use the formulas below: area = Pi * radius * radius perimeter = 2 *Pi * radius Where value of Pi is 22/7 = 3.14 Display the computed area and perimeter.
- Given an airplane's acceleration and take-off speed v, you can compute the minimum runway length needed for an airplane to take off using the following formula. length=v^2/2*a. write a program that prompts the user to enter V in meters and acceleration an in meter/second and display the minimum runway length.Given an airplane’s acceleration a and take-offspeed v, you can compute the minimum runway length needed for an airplane totake off using the following formula:length =v2/2aWrite a program that prompts the user to enter v in meters/second (m/s) and theacceleration a in meters/second squared (m/s2), then, displays the minimum runwaylength. Here is a sample run: Enter speed and acceleration: 60 3.5The minimum runway length for this airplane is 514.286Write a program which takes the user's age in years and convert it into months. 1 Year = 12 Months %3D