Advertisement
ssunlimited

Untitled

Jun 27th, 2022
1,152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.33 KB | None | 0 0
  1. import java.util.*;
  2.  
  3. public class SortCompare implements Comparator<Integer>{
  4.    int a = 3;
  5.    public static void main(String[] args) {
  6.       System.out.println(compare(3, 4));
  7.    }
  8.    
  9.    @Override
  10.    public int compare(Integer o, Integer b){
  11.       return o-b;//maybe create class that uses this class.
  12.       }
  13.    
  14.    }
  15.  
  16.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement