import java.util.*; class Main { public static void main(String[] args) { Scanner in = new Scanner(System.in); int a = in.nextInt(); int b = in.nextInt(); HashSet set = new HashSet<>(); for(int i=0; i<=a; i++) { for(int j=0; j<=b; j++) { if(i != 0 || j != 0) set.add(i + j*5); } } ArrayList list = new ArrayList<>(); Iterator it = set.iterator(); while(it.hasNext()) list.add(it.next()); Collections.sort(list); for(int i=0; i