Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. public class Test{
  2.     public static void main(String []args){
  3.         java.util.Scanner in=new java.util.Scanner(System.in);
  4.         System.out.print("Input Threshold\t\t:");
  5.         double tres=in.nextDouble();
  6.         System.out.print("Input Alpha\t\t:");
  7.         double alpha=in.nextDouble();
  8.         System.out.print("Input weight1, w1\t:");
  9.         double w1=in.nextDouble();
  10.         System.out.print("Input weight2, w2\t:");
  11.         double w2=in.nextDouble();
  12.        
  13.         Perceptron p=new Perceptron();
  14.         p.initialize(tres,alpha,w1,w2);
  15.         p.start();
  16.         System.out.println(p.toString());
  17.        
  18.         System.exit(0);
  19.     }
  20. }