morriskaleb06 morriskaleb06
  • 16-09-2022
  • Computers and Technology
contestada

write a complete main that will input a decimal number, double it and display the results

write a complete main that will input a decimal number double it and display the results class=

Respuesta :

NotAStudentxD NotAStudentxD
  • 16-09-2022

Answer:

No sure what language you want but since I am best with Java.

class Main {

 public static void main(String[] args) {

   Scanner input = new Scanner(System.in);  // Create a Scanner object

   System.out.println("Enter Number");

double number01 = input.nextLine();  // Read user input

double multi = number01 * 2;

   System.out.println("Number is " + multi);  // Output user input

}

}

Explanation:

Answer Link

Otras preguntas

Two brothers are saving money to buy tickets to a concert. their combined saving is $55 one brother has $15 more than the other. How much has each saved?
Which is the definition of refraction
Fill in the integers -10, -8, -7, -6, -5, -4, -3, -2 and 0 into a magic square so that every row, column, and diagonal has a sum of -15.
In planning to conduct research it is very important to have and start with a(an)
What is five plus (-12)
What is 25% of 279.00
If an attention line is required on a business letter envelope, the United States Postal Service recommends placing it A. above the recipient's name.
Geometry math question no Guessing Please help
What technologies did humans develop which allowed them to adapt to new environments
According to this cartoon, women suffragists argued that giving women the right to _____ would make politics cleaner. apex