Advertisement
mmayoub

Ex01, 24.04.2021

Apr 25th, 2021
871
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.54 KB | None | 0 0
  1. // 24.04.2021
  2. import java.util.Scanner;
  3.  
  4. public class Ex01 {
  5.  
  6.     public static void main(String[] args) {
  7.         // TODO Auto-generated method stub
  8.  
  9.         Scanner in = new Scanner(System.in);
  10.  
  11.         // double sa3at ;
  12.         // double ajrSa3a;
  13.         // double ajrShahri;
  14.  
  15.         double sa3at, ajrSa3a, ajrShahri;
  16.  
  17.         System.out.print("number of hours: ");
  18.         sa3at = in.nextDouble();
  19.  
  20.         System.out.print("price for hour: ");
  21.         ajrSa3a = in.nextDouble();
  22.  
  23.         ajrShahri = sa3at * ajrSa3a;
  24.  
  25.         System.out.println("Toatal salary = " + ajrShahri);
  26.  
  27.         in.close();
  28.     }
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement