Q2: Write a FORTRAN90 program that reads a student ID and his GPA out of 4.0. The program should print a message according to the following Condition Message EXCELLENT VERY GOOD GPA >= 3.5 3.5> GPA > 3,0 3.0 > GPA > 2,5 2.5 > GPA >n 2,0 GPA<2.0 GOOD FAIR POOR
Q: rite a program that uses switch statement to enter the grades A, B, C, D or F. Your program should…
A: Given: Write a program that uses switch statement to enter the grades A, B, C, D or F. Your program…
Q: For the expression, c = (a!=b)?d:e; e will be assigned to c if: O a is greater than b O a is less…
A: Solution The given scenario has a ternary operator. The ternary operator checks a test condition and…
Q: Q.5) Write a C++ code that asks the user's name , then the code will ask the user to guess the…
A: #include <iostream>using namespace std;int main(){ //varibale to hold name string name;…
Q: Q2 - Write a program by FORTRAN90 language to find the value of 'y'from the following equations: 3…
A: Step 1:- Program Approach:- 1.Declare the variable x and y as real data type 2.Take the input…
Q: c. Write the output of the code given below? for( x=1; x <= 5; x++ ); { cout << "Hello World: " <<…
A: The output is as follows: Hello World: Hello World: Hello World: Hello World:
Q: C++ Write a program to overload the operator ‘+’ for complex numbers.
A: #include <iostream>using namespace std; class Complex{public: float r; float i; Complex(){…
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: 5. Write a program that reports whether someone is eligible to run for president in the U.S. You…
A: According to the information given:- We have to follow instruction to create eligibility criteria
Q: ABC Bank announced a new scheme of reward points for a transaction using an ATM card.Each…
A: Code: import java.util.*;public class Demo{ public static void main(String args[]) { Scanner…
Q: ite a program InOrder that reads in three different integers and prints the three integers in…
A: In Python we use input function to get input from the user. We can use it like this a = input ("…
Q: (int score) Returns how many entries in the scoreboard are greater than or equal to the given score.…
A: Q. Use C++ Programming int exemplary(int score) Returns how many entries in the scoreboard are…
Q: Write a program that calculates and displays a person's body mass index (BMI). The BMI is often used…
A: Answer in step2
Q: An internet service provider has three different subscription packages for its customers:…
A: In this JAVA program, We have to calculate the total bill for number of hour watched and package…
Q: Q2) Write code in VB.NET using "do .. while" to solution the following : 14 5 * xy2 i=6 If output is…
A: Code:…
Q: Read and understand the following problem: 1. Write a program that accepts from the user an…
A: Suppose the user entered 100 Peso. Given: 1 HK dollar = Php 6.51 ⇒ 1 Php = 1/6.51 HK dollar…
Q: Suppose you deposit a certain amount of money into a savings account that earns compound monthly…
A: The below-given javascript program will obey the following rubrics: Declaring a function,…
Q: (S), Il ally, I ) #include main() { int x[5], *y,z[5] for(i=0;i void main(){ int x,y; cin>>x; for…
A: Answer is given below. (i) Will encounter a following syntax error(s): The variable ‘i’ is not…
Q: PRG11: Write a program that will calculate and show bills of the Manila Electric Company. The rates…
A: #include<stdio.h>int main(){ int subId, consumption; float bill; char name[40],type;…
Q: Q3: Write a VB program to enter a mark of a student and then find his grade as follows: If mark >=75…
A: VB program is asked with the following conditions: If mark>=75 print Grade = A If…
Q: hello, i am having problems with this hw question, Explain the problem with the following code:…
A: I have provided c++ code with comments in step2
Q: Consider the statement int val[2] [4] = { 1, 2, 3, 4, 5, 6, 7, 8} ; 4 will be the value of A.…
A: We are given a 2-d array and we are going to find out how an element 4 which is present in the array…
Q: A corporation named XYZ needs a program to calculate how much to pay their part-time and full-time…
A: The program code is : - for XYZ company : class Employee: def…
Q: Write a program that uses a switch statement as follows: If game contains the letter p , or P the…
A: C++ Program: #include <iostream>using namespace std; // Function print the words Play Station…
Q: In investment analysis,the following equation is frequently used; A=P(1+r/100)n Where n =10 years.…
A: PHP program to find A = P(1+r/100)n
Q: C# program named TestScoreList that accepts eight int values representing student test scores.…
A: Given Write a C# program named TestScoreList that accepts eight int values representing student test…
Q: Q/lf 72 = mark is an integer variable and grade is a symbolic variable then the output to be printed…
A: The if-else-if ladder statement executes one condition from multiple statements. Exceution happens…
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: After Exception of following statements: int x, y; char ch; cin ignore (7,'2'); cin.get(ch); cin…
A: ignore() function is used which is used to ignore or clear one or more characters from the input…
Q: A java program that works out the charges for the month. The program should accept the following on…
A: //import the required package import java.util.Scanner; //Definition of the main class public class…
Q: 2. Write a program that takes an amount in pesos and breaks it down to bills (1000, 500, 100, 50,…
A: Write a program that takes an amount in pesos and breaks it down to bills (1000, 500, 100, 50, 20)…
Q: What is the last value of x, y and z? int x = 3, y =5, z = 0; %3D if (x > 0) Z - X; if (z > 0) x =…
A: I have provided both answer with it's output in step 2
Q: Fox International sells pre-paid calling card with the following features: Calls to USo 1.2 cents…
A: Java program to create the Fox International Calling Card Calculator.This program takes account…
Q: 9- The script in the left side is used to solve the right-side equation. #include #include using…
A:
Q: Make a flowchart where a program dispenses cash at an ATM machine that has been upgraded to dispense…
A: Since you needed the output screenshot I am attaching for both conditions thatis when amount is…
Q: 8. Write a program that will compute delivery charges based on weight Weight Up to 100 lb Charge per…
A: A program is as follows, Code: %Get the input from the user weight=input('Please enter weight of…
Q: 5. Write a program that reports whether someone is eligible to run for president in the U.S. You…
A: According to the information given:- We have to create a program to satisfy the output.
Q: Q2) Write code in VB.NET using "do .. while" to solution the following : 14 5 * xy? i=6 If output is…
A: Input : Input x Input y Output : Calculate the given expression value using a do-while loop. If…
Q: A sales event at Trader Jane's is reducing some items by 25%. Store that value to a properly named…
A: Introduction of Program The C++ Program provided with the Reducing Offer and the Sales Tax values of…
Q: Q2/-A- What is printed by the following code fragment? Int x1=4 , y1, x2=6, y2; yl=++x1; y2=x2++;…
A: The code fragment given: int x1 = 4, y1, x2=6, y2; y1 = ++x1; y2 = x2++; x2 = y1++; cout…
Q: 2-Fully explain the following code and draw all possible outputs. Please input a number between 5…
A: Given code: <!DOCTYPE html> <html> <body> <p>Please input a…
Q: 8. Write a program that calculates and displays a person's body mass index (BMI). The BMI is often…
A: Input weight, height Calculate BMI Use if conditional statements to check the person condition based…
Q: In java write a program that takes four int command-line arguments w, x, y, z,. define a boolean…
A: The java program and its approach are given below: - Approach: - Defining the main class and…
Q: Write a unit conversion program that asks the users from which unit they want to convert (gal, oz,…
A: //Code In Java import java.util.*; public class Main{ public static void main(String[] args) {…
Q: int y = !(12 x) ? 7 : 9 Based on the code above, what is the value of y if x = 1?
A: This question comes from Programming Language which is a paper of computer science. Let's discuss it…
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: 3. A fast food restaurant sells the following products: Product Burgersteak Softdrinks Price PhP…
A: I have given C++ code to count the total amount paid by customer to by products.
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…
Q: If, A = {3, 5, 7, 9} B = {2, 4, 6, 8, 10} C = {12, 14, 18, 20, 24} D = {21, 26, 31, 36} A.…
A: Given sets are: A = {3, 5, 7, 9} B = {2, 4, 6, 8, 10} C = {12, 14, 18, 20, 24} D = {21, 26, 31, 36}…
Step by step
Solved in 3 steps with 1 images
- Write a program in C that displays the classic BINGO game, displays a BINGO card (5x5 square), and tests the bingo card for a winner via 2 users Steps: 1- Ask user 1 to enter 24 numbers between 10-40 no duplicates / check for range and repetition 2- Ask user 2 to enter 24 numbers between 10-40 no duplicates / check for range and repetition 3- Design 2 BINGO cards as you see below 4- Distribute the numbers onto the 2 cards with each user input with 0 in the middle 5- Display the 2 cards in 1 screen as you see below 6- Generate a random number between 10-40 no duplicates / check for range and repetition 7- Compare the random number with the numbers on the 2 cards 8- If the random number matches any number on each card, change the number on the card to 0 9- Check for winning cards 5 numbers in a row or column = 0 5 numbers in a diagonal = 0 all 4 corners of the card = 0 if any of the players won, display who is the winner and exit the program if the 2 players won, display both are…PROBLEM: I need to make an ATM program that allows the user to check his or her balance after entering his or her correct PIN and the maintaining balance is Php 8000. A message is shown when the balance is below PHP 8,000 for withdrawal and its remaining balance. Another message is shown when the balance is PHP 8,000 and above for deposit and its updated balance. The code: import random import sys class ATM(): def __init__(self, name, account_number, balance = 0): self.name = name self.account_number = account_number self.balance = balance def account_detail(self): print("\n----------ACCOUNT DETAIL----------") print(f"Account Holder: {self.name.upper()}") print(f"Account Number: {self.account_number}") print(f"Available balance: Nu.{self.balance}\n") def deposit(self, amount): self.amount = amount self.balance = self.balance + self.amount print("Current account…A number in base 2 (binary) is a number such that each of its digits is 0 or 1. To convert frombinary to decimal (base 10), the digits starting from the right are multiplied by powers of 2(starting at 0) and added. For example, the value in decimal of 10011 is calculated as follows: 1 ×20+ 1 ×21+ 0 ×22+ 0 ×23+ 1 ×24=19 Write a program that reads from the user a 5-digit integer representing a value in binary anddisplays its equivalent value in decimal. Note that if the user enters an integer which digits areother than 0 or 1, the program displays a message stating that the number is not valid.
- In Python, A sales event at Trader Jane's is reducing some items by 25%. Store that value to a properly named constant. Write a program that functions like a cashier terminal for one item. Some items are subject to 7% sales tax and some are not. Use a constant for the sales tax value, too. Write a program for Trader Jane's that runs as shown next: Enter the ticket price of the item 100 Is this item reduced y/n? y is this item taxable y/n? y Here is your bill Original price $100 Reduction during event $25.00 Final price $75.00 7% Sales tax $5.25 Total amount due $80.25 Plan each program by writing pseudocode. Write all of your pseudocode as comments immediately after your name and SPC ID#. Add more comments as needed in each program to explain your code. Choose descriptive variable names in all programs. Currency format. There should be no space between the $ sign and the first digit. See sep on page 66 to cancel the space automatically added when print items are separated by…7. Write a C - program that accepts two integers from the user and then prints the sum, the difference, the product, the average, the distance (the difference between integer), the maximum (the larger of the two integers), the minimum (smaller of the two integers). Test Data Input 1st integer: 25 Input 2nd integer: 5 Expected Output : Sum of two integers: 30 Difference of two integers: 20 Product of two integers: 125 Average of two integers: 15.00 Distance of two integers: 20 Max integer: 25 Min integer: 5What is the output assuming dynamic scoping and static scoping! Give answers for both dynamic and static! #include <iostream> using namespace std; int total = 5; int c = 3; int fun1(int); int fun2(int); int main() { int x = 2; int y = 8; cout << " variables x y and c have values: " << x <<" " << y << " " << c << endl; cout << "main: fun1(x) = " << fun1(x) << endl; cout << " After Call to fun1(x) variables x y and c have values: " << x <<" " << y << " " << c << endl; return 0; } int fun1(int a) { int b = 6; int c = 3; b = total + c + a; cout << "in fun1: b= " << b << endl; cout << "in fun 1 after call to fun2(total) the return value is " << fun2(total) << endl; return (b); } int fun2(int w) { c = c * 2; total = total + w + c; cout << "in fun2: total= " << total << endl; return(c); }
- Write a C++ program that allows a user to enter their rating of the three movies in the Dark Knight Trilogy: Batman Begins The Dark Knight The Dark Knight Rises Ratings must be between 1 and 5. If a rating entered is less than 1 or more than 5, display an appropriate error message, and ask for a new rating. After all the ratings have been entered, display each rating entered, the highest rating, the lowest rating, and the average of the ratings.Write a console application in c++ that prints the next 20 leap years. A leap year is a year in which an extra day is added to the Gregorian calendar, which is used by most of the world. While an ordinary year has 365 days, a leap year has 366 days. ... A leap year comes once every four years. Because of this, a leap year can always be evenly divided by four.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.
- i). Write a C++ program to prompt the user to input her/his age and print it on the screen, asshown below.Your age is 20 years old. ii). Write a C++ program that asks the user for a number n and gives him the possibility to choosebetween computing the sum and computing the product of 1,...,n iii). Write a program that asks the user for a number n and gives him the possibility to choosebetween computing the sum and computing the product of 1,...,n. Expected output: 0,30,25,28Create a program in c++ that gets quarterly sales from a user, and calculates the total of all four quarters as well as the average, lowest, and highest quarters. Console Example that should be followed when executed The Quarterly Sales program Enter sales for Q1: 12312.57 Enter sales for Q2: 15293.21 Enter sales for Q3: 14920.95 Enter sales for Q4: 23432.21 Total: 65958.94 Average Quarter: 16489.74 Lowest Quarter: 12312.57 Highest Quarter: 23432.21 Specifications: Create the pseudocode needed to implement the solution above. Convert your pseudocode to C++ code including the following specifications: ROUND the average quarter to a maximum of 2 decimal digits. Use a vector to store the sales for each quarter. Use STL algorithms to process the data for the quarters. Please make sure the average is ROUNDED 2 places to get the output 16489.74 instead of 16489.73Program32.java Write a program that prompts the user for any day of the week. Report the entered day as either a weekend day, or not. Use a switch and "stack" cases that require the same report as shown on page 103. Your program should handle bad inputs, too. Program33.java Write a program that generates a random Fahrenheit oral temperature between 92 and 108, inclusive. Print the temperature, and then report whether the temperature indicates a fever or not using a conditional operator as on page 105. An oral temperature above 100F is feverish. Program34.java Write a program that prints the ordinal for a random integer from 0 to 100, inclusive. Example ordinals might be 31st, 62nd, 43rd, 55th. Program41.javaWrite a program that prompts the user to enter a full name consisting of three names (first middle last) into one String variable. Then use methods of class String to: print the number of characters in the full name, excluding spaces print just the middle name and the number of…