Skip to main content
deleted 2 characters in body
Source Link
Dominic van Essen
  • 36.4k
  • 2
  • 22
  • 60

R, (29 bytes -15 -5) = 914

cos(m<-scan()*pi/2)+sin(m)*1i

Try it online!

Conventional complex number output; works for negative and real inputs.

(for completeness, there is also c(1,scan()*90) for a score of -61, using theblutorange's dubious inventive polar output format in degrees)

R, (29 bytes -15 -5) = 9

cos(m<-scan()*pi/2)+sin(m)*1i

Try it online!

Conventional complex number output; works for negative and real inputs.

(for completeness, there is also c(1,scan()*90) for a score of -6, using the dubious inventive polar output format in degrees)

R, (29 bytes -15) = 14

cos(m<-scan()*pi/2)+sin(m)*1i

Try it online!

Conventional complex number output; works for negative and real inputs.

(for completeness, there is also c(1,scan()*90) for a score of -1, using blutorange's dubious inventive polar output format in degrees)

Source Link
Dominic van Essen
  • 36.4k
  • 2
  • 22
  • 60

R, (29 bytes -15 -5) = 9

cos(m<-scan()*pi/2)+sin(m)*1i

Try it online!

Conventional complex number output; works for negative and real inputs.

(for completeness, there is also c(1,scan()*90) for a score of -6, using the dubious inventive polar output format in degrees)