Skip to main content
2 of 2
added 59 characters in body
JDL
  • 1.7k
  • 13
  • 18

R, 47 46 bytes

n=scan();cat(rep(c("\\","/")[n%%2+1],n),sep="")

In R, you have to escape backslashes. the argument sep also has to be fully specified since it comes after .... Thus annoyingly few opportunities to save chars :(

Thanks to bouncyball for golfing away a byte.

JDL
  • 1.7k
  • 13
  • 18