Skip to content

Instantly share code, notes, and snippets.

unserializable

Block or report user

Report or block unserializable

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@unserializable
unserializable / SumEvenFibo_lt_4M.java
Created Jun 1, 2017
Sum even Fibonacci numbers not exceeding 4 million (Project Euler Problem #2)
View SumEvenFibo_lt_4M.java
/*
Minimalistic (length-wise) looping Java code for Project Euler problem #2 (https://projecteuler.net/problem=2).
Finds the sum of /even/ Fibonacci numbers which do not exceed 4 million.
^= operater use for variable swap in Java cannot be as compact as in C, see:
http://stackoverflow.com/questions/3844934/why-is-this-statement-not-working-in-java-x-y-x-y
@author Taimo Peelo
*/
public class SumEvenFibo_lt_4M {
public static void main(String[] args) { // Output is 4613732
@unserializable
unserializable / NextFriday13th.java
Created Jan 13, 2017
Temporal play, with Friday the 13th example.
View NextFriday13th.java
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.time.*;
import java.time.format.DateTimeFormatter;
import java.time.temporal.ChronoUnit;
import java.time.temporal.TemporalQuery;
import static java.time.DayOfWeek.FRIDAY;
import static java.time.temporal.ChronoField.DAY_OF_MONTH;
@unserializable
unserializable / JdkTlsCipherSuiteList.java
Last active Jan 9, 2017
Lists the enabled / available ciphersuites from the running JDK
View JdkTlsCipherSuiteList.java
import javax.net.ssl.SSLSocketFactory;
import java.util.Set;
import static java.util.Arrays.stream;
import static java.util.stream.Collectors.toSet;
/**
* @author Taimo Peelo
*/
public class JdkTlsCipherSuiteList {
You can’t perform that action at this time.