Skip to main content
deleted 24 characters in body
Source Link
Martijn
  • 161
  • 1
  • 6

Scala, 10996 bytes

#!/usr/bin/sh execenv scala "$0" "$@" !# print(((a:Int)=>if(a==2)true;else!2.to(a-1).exists(a%_==0))(args(0).toInt)) 

JVM and yet not last place :D

Does use some bash functionality but I'm using Scala so don't be too hard on me.

Scala, 109 bytes

#!/bin/sh exec scala "$0" "$@" !# print(((a:Int)=>if(a==2)true;else!2.to(a-1).exists(a%_==0))(args(0).toInt)) 

JVM and yet not last place :D

Does use some bash functionality but I'm using Scala so don't be too hard on me.

Scala, 96 bytes

#!/usr/bin/env scala print(((a:Int)=>if(a==2)true;else!2.to(a-1).exists(a%_==0))(args(0).toInt)) 

JVM and yet not last place :D

Does use some bash functionality but I'm using Scala so don't be too hard on me.

Source Link
Martijn
  • 161
  • 1
  • 6

Scala, 109 bytes

#!/bin/sh exec scala "$0" "$@" !# print(((a:Int)=>if(a==2)true;else!2.to(a-1).exists(a%_==0))(args(0).toInt)) 

JVM and yet not last place :D

Does use some bash functionality but I'm using Scala so don't be too hard on me.