What's new

Calling my IT friends q

rzhernandez

Eternal Poster
Established
Joined
Sep 29, 2017
Posts
920
Reaction
327
Points
419
received_508455473945282.jpeg

Baka po may alam kayo mag coding...helping for a friend lang
 

Attachments

public static void main (String [] args) {

int Employeehours = 0;
double RPH = 42.62;


Scanner input = new Scanner(System.in);
System.out.println("WELCOME TO EMPLOYEE'S PAYROLL!");
System.out.print("Please Enter Your Total Number of Hours: ");
Employeehours = input.nextInt();
double Grossincome = Employeehours * RPH;
System.out.println(Employeehours+ " * " +RPH + " = " + Grossincome);
System.out.println("Your total Gross Income Is: " + Grossincome);

input.close();
}
 
Multiply mo lang yung input (total number of hours) dun sa rate per hour.

Java:
import java.util.*;

public class MyClass {
    public static void main(String args[]) {
      double input, result;
      double hourlyRate = 42.62;
      
      Scanner s = new Scanner(System.in);
      System.out.println("Input total number of hours: ");
      input = s.nextDouble();
      
      result = input * hourlyRate;
      
      System.out.println("Gross income: " + result);
      
    }
}
 
Multiply mo lang yung input (total number of hours) dun sa rate per hour.

Java:
import java.util.*;

public class MyClass {
    public static void main(String args[]) {
      double input, result;
      double hourlyRate = 42.62;
     
      Scanner s = new Scanner(System.in);
      System.out.println("Input total number of hours: ");
      input = s.nextDouble();
     
      result = input * hourlyRate;
     
      System.out.println("Gross income: " + result);
     
    }
}
Pinasa pa yung assignment satin HAHAHAHAHAHA
 
Advice lang, kung ngayon palang nahihirapan na kayo sa ganyan. How much more pa sa industry ng IT kapag nagka work na kayo 🙂 You should try challenge yourself hehe. Just saying lang
 

Similar threads

Back
Top