Contoh Program Prosedur
Contoh Program Prosedur
Contoh Program Prosedur
Voltage : Proses 1
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package prosedur;
import java.util.Scanner;
/**
*
* @author destyrodiah-pc
*/
public class Voltage1 {
/**
* @param args the command line arguments
*/
public static int R,A,V;
Voltage : Proses 2
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package prosedur;
import java.util.Scanner;
/**
*
* @author destyrodiah-pc
*/
public class Voltage2 {
/**
* @param args the command line arguments
*/
}
}
Tukar
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package prosedur;
import java.util.Scanner;
/**
*
* @author destyrodiah-pc
*/
public class Tukar {
public static int x,y;
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
Scanner input = new Scanner(System.in);
System.out.print("Masukkan x :");
x = input.nextInt();
System.out.print("Masukkan y :");
y = input.nextInt();
proctukar(x, y);