23 lines
261 B
Bash
Executable File
23 lines
261 B
Bash
Executable File
#!/usr/bin/sh
|
|
|
|
DAY=1
|
|
if [ -n "$1" ]; then
|
|
DAY=$1
|
|
fi
|
|
|
|
PART=1
|
|
if [ -n "$2" ]; then
|
|
PART=$2
|
|
fi
|
|
|
|
INPUT=my
|
|
if [ -n "$3" ]; then
|
|
INPUT=$3
|
|
fi
|
|
|
|
mkdir -p bin
|
|
|
|
set -e
|
|
|
|
echo -n "Day $DAY part $PART with '$INPUT' input: "
|
|
bin/day${DAY}p$PART < day$DAY/in.$INPUT |