This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p_9386c3c805d7da9ebb7b7814daf688b3; | |
import java.io.IOException; | |
import java.time.DateTimeException; | |
import java.time.chrono.Chronology; | |
import java.time.temporal.ChronoField; | |
import java.time.temporal.ValueRange; | |
import java.util.function.BiConsumer; | |
public class ValueRanges { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package g_79ff0bed607bef315c4353b374e1319e; | |
import java.util.ArrayList; | |
import java.util.List; | |
import java.util.Objects; | |
import static java.util.Objects.requireNonNull; | |
/** | |
* A program solves <a href="https://en.wikipedia.org/wiki/Tower_of_Hanoi">Tower of Hanoi</a>. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# https://gist.github.com/onacit/9f79215aaf6bd8d59e78ed6a38b93889 | |
# https://stackoverflow.com/questions/3545292/how-to-get-maven-project-version-to-the-bash-command-line | |
if [ $# -lt 2 ]; then | |
echo "Usage: $0 <tag> <phases...>, e.g. $0 3-jdk-11-openj9 clean install" | |
echo "See https://hub.docker.com/_/maven for available tags" | |
exit 1 | |
fi | |
groupId=$(mvn help:evaluate -Dexpression=project.groupId | grep -v '\[') | |
artifactId=$(mvn help:evaluate -Dexpression=project.artifactId | grep -v '\[') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import datetime | |
from datetime import timedelta | |
import getpass | |
import json | |
try: | |
import requests | |
except ImportError: | |
sys.exit("run pip install requests") | |
from requests.auth import HTTPBasicAuth | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# https://gist.github.com/onacit/036c93befff929a1f43b7603aa0b65bb | |
if [ $# -lt 3 ]; then | |
echo "Usage: $0 <tag> <tasks...>, e.g. $0 6.0.1-jdk11 -Pprofile=local clean build" | |
echo "See https://hub.docker.com/_/gradle for available tags" | |
exit 1 | |
fi | |
tag="$1" | |
shift | |
name=$(basename "$PWD") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p_0dd925d3768fcd4f79494ae32905dc1b; | |
import java.util.Comparator; | |
import java.util.List; | |
import static java.util.Objects.requireNonNull; | |
/** | |
* A class implements <a href="https://en.wikipedia.org/wiki/Selection_sort">Selection sort</a>. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p_4cb92ba58cd8e8ab40d7e734e1f86ce1; | |
import javax.validation.constraints.NotNull; | |
import java.util.Collections; | |
import java.util.HashMap; | |
import java.util.Map; | |
import java.util.Objects; | |
import static java.util.Objects.requireNonNull; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p_fd0b04b007e395a7fcfc5066898d422d; | |
import java.util.Arrays; | |
import java.util.Comparator; | |
import java.util.List; | |
import java.util.Map; | |
import java.util.SortedMap; | |
import java.util.TreeMap; | |
import java.util.stream.Collectors; | |
import java.util.stream.IntStream; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Arrays; | |
import java.util.Objects; | |
public final class CaesarCipher { | |
/** | |
* Creates a new instance with specified shift. | |
* | |
* @param shift the shift | |
*/ |
NewerOlder