Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.
Code Golf

Return to Answer

deleted 82 characters in body
Source Link
rev
  • 39
  • 3

05AB1E, 17(削除) 17 (削除ここまで) 16 bytes

" "Ç©IED®âO«]I¢ŽGç2в©IED®âO«]I¢

Try it online! Try it online!

Explanation

" "  String containing code points for 6, 9, and 20
 Ç ŽGç2в Convert code points to integerThe list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input

05AB1E, 17 bytes

" "Ç©IED®âO«]I¢

Try it online!

Explanation

" "  String containing code points for 6, 9, and 20
 Ç  Convert code points to integer list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input

05AB1E, (削除) 17 (削除ここまで) 16 bytes

ŽGç2в©IED®âO«]I¢

Try it online!

Explanation

 ŽGç2в The list [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input
deleted 123 characters in body
Source Link
rev
  • 39
  • 3

05AB1E, 17 bytes

" "Ç©IED®âO«]I¢

Try it online!

Explanation

" " String containing code points for 6, 9, and 20
 Ç Convert code points to integer list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input

Try it online!

05AB1E, 17 bytes

" "Ç©IED®âO«]I¢

Try it online!

Explanation

" " String containing code points for 6, 9, and 20
 Ç Convert code points to integer list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input

Try it online!

05AB1E, 17 bytes

" "Ç©IED®âO«]I¢

Try it online!

Explanation

" " String containing code points for 6, 9, and 20
 Ç Convert code points to integer list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input
Source Link
rev
  • 39
  • 3

05AB1E, 17 bytes

" "Ç©IED®âO«]I¢

Try it online!

Explanation

" " String containing code points for 6, 9, and 20
 Ç Convert code points to integer list to get [6, 9, 20]
 © Store this list in register_c
 IE Loop <input> number of times
 ®â Cartesian product stack contents with list in register_c
 O Sum up the contents of each sub array
 D « List duplicated before taking Cartesian product, concat
 ] End for loop
 I¢ Count occurences of input

Try it online!

AltStyle によって変換されたページ (->オリジナル) /