Skip to main content
Commonmark migration
Source Link

#Dyalog APL, 32 33 bytes

Dyalog APL, 32 33 bytes

⍕¨{⍵-3↑31 11≡2↑⍵}31 12 1E4⌊⍎∊⍕⌽¨⎕

I/O is list of three strings ('dd' 'mm' 'yyyy').

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

#Dyalog APL, 32 33 bytes

⍕¨{⍵-3↑31 11≡2↑⍵}31 12 1E4⌊⍎∊⍕⌽¨⎕

I/O is list of three strings ('dd' 'mm' 'yyyy').

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

Dyalog APL, 32 33 bytes

⍕¨{⍵-3↑31 11≡2↑⍵}31 12 1E4⌊⍎∊⍕⌽¨⎕

I/O is list of three strings ('dd' 'mm' 'yyyy').

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

I/O now in same format.
Source Link
Adám
  • 31.1k
  • 3
  • 124
  • 287

#Dyalog APL, 3232 33 bytes

⍕¨{⍵-3↑31 11≡2↑⍵}31 12 9999⌊⍎∊⍕⌽¨⎕1E4⌊⍎∊⍕⌽¨⎕

Prompts for input in the formatI/O is list of three strings ('dd' 'mm' 'yyyy' and returns a list of three numbers).

TryAPLTryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

#Dyalog APL, 32 bytes

{⍵-3↑31 11≡2↑⍵}31 12 9999⌊⍎∊⍕⌽¨⎕

Prompts for input in the format 'dd' 'mm' 'yyyy' and returns a list of three numbers.

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

#Dyalog APL, 32 33 bytes

⍕¨{⍵-3↑31 11≡2↑⍵}31 12 1E4⌊⍎∊⍕⌽¨⎕

I/O is list of three strings ('dd' 'mm' 'yyyy').

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

Try online
Source Link
Adám
  • 31.1k
  • 3
  • 124
  • 287

#Dyalog APL, 32 bytes

{⍵-3↑31 11≡2↑⍵}31 12 9999⌊⍎∊⍕⌽¨⎕

Prompts for input in the format 'dd' 'mm' 'yyyy' and returns a list of three numbers.

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

#Dyalog APL, 32 bytes

{⍵-3↑31 11≡2↑⍵}31 12 9999⌊⍎∊⍕⌽¨⎕

Prompts for input in the format 'dd' 'mm' 'yyyy' and returns a list of three numbers.

#Dyalog APL, 32 bytes

{⍵-3↑31 11≡2↑⍵}31 12 9999⌊⍎∊⍕⌽¨⎕

Prompts for input in the format 'dd' 'mm' 'yyyy' and returns a list of three numbers.

TryAPL, but note that (prompt for input) has been replaced with and the entire line enclosed in {...} to enable online testing, and (execute expression) has been replaced with 2⊃⎕VFI (verify and fix input) because execution of arbitrary code is blocked.

Source Link
Adám
  • 31.1k
  • 3
  • 124
  • 287
Loading