Skip to content

Instantly share code, notes, and snippets.

@gjp0609
Created January 7, 2019 08:09
Show Gist options
  • Save gjp0609/e6d0cd79c877cb4c880dd60cafcb643d to your computer and use it in GitHub Desktop.
Save gjp0609/e6d0cd79c877cb4c880dd60cafcb643d to your computer and use it in GitHub Desktop.
One line test
Jsoup.parse(new BufferedReader(new FileReader(new File("C:/Files/ps4.html"))).lines().reduce(Jsoup.parse(new BufferedReader(new FileReader(new File("C:/Files/ByUser.html"))).lines().reduce("", (acc, item) -> acc + item)).toString(), (acc, item) -> acc + item)).select(".product_wrap").stream().sorted(Comparator.comparing(e -> ((Element) e).select(".textscore").text()).reversed()).map(item -> "\033[106m ".concat(item.select(".textscore").text()).concat(" \033[102m ").concat(String.format("%3s", item.select(".metascore_w").text())).concat(" \033[91m ").concat(item.select("a").text())).distinct().forEach(System.out::println);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment