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

Please make this sentence more descriptive (anything works). "I walk on the icy road towards the eery house."
A 48 meter antenna mast is stabilized by a 52 meter guy wire How far from the base of the mast is the guy wire secured to the ground A 20m B 50m C 60m D 100m
State three economic importance of mucor
Both independent and dependent clauses express complete thoughts. have a subject and verb. do not express complete thoughts. do not have a subject but do have a
How many pairs of points are reflections across the x-axis? A. 1 B. 2 C. 3 D. 4
What’s the correct answer for this question?
Based on their anatomical similarities which of the three of these organisms share a close evolutionary Laois and ship a snake a horse a ladybug human or bacter
Which verb or verb phrase is in the correct tense to complete the sentence? Tomorrow night when we take the ghost tour of the city, I ________ in my boots, hopi
Simplify 10x - 3x + (-5x).
Find the value of x.