Skip to main content
deleted 231 characters in body
Source Link
Rudier
  • 2.1k
  • 10
  • 21

R, 2213 bytes

catsum(scan(n=2),sep="1"+1)

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows howThanks to stop the scan functionJonathan Allan for his inputs (i.e. by giving a blank line as the input).!

R, 22 bytes

cat(scan(n=2),sep="1")

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

R, 13 bytes

sum(scan()+1)

Thanks to Jonathan Allan for his inputs !

added 1 character in body
Source Link
Rudier
  • 2.1k
  • 10
  • 21

R, 2122 bytes

cat(scan(n=2),sep=""sep="1")

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

R, 21 bytes

cat(scan(n=2),sep="")

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

R, 22 bytes

cat(scan(n=2),sep="1")

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

Post Undeleted by Rudier
added 61 characters in body
Source Link
Rudier
  • 2.1k
  • 10
  • 21

R, 1221 bytes

cat(scan(n=2)[1],sep="")

Takes exactly 2 numbers as the input, and outputs the first oneboth of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

R, 12 bytes

scan(n=2)[1]

Takes exactly 2 numbers as the input, and outputs the first one.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

R, 21 bytes

cat(scan(n=2),sep="")

Takes exactly 2 numbers as the input, and outputs both of them sticked together, thus creating a new natural number.
The n=2 adds 3 bytes and is perhaps unecessary, if the user knows how to stop the scan function (i.e. by giving a blank line as the input).

Post Deleted by Rudier
Source Link
Rudier
  • 2.1k
  • 10
  • 21
Loading