run.sh 195 B

12345678910111213141516
  1. IN="$(mktemp --suffix .HC)"
  2. OUT="$(mktemp)"
  3. cat > "$IN"
  4. LOG="$(hcc $IN 2>&1)"
  5. if [ $? -eq 0 ]; then
  6. OUT="$(mktemp)"
  7. mv ./a.out "$OUT"
  8. chmod +x "$OUT"
  9. exec "$OUT"
  10. else
  11. echo "$LOG"
  12. fi