Skip to main content
Commonmark migration
Source Link

#Ruby, 78#

Ruby, 78

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

Ruby, 96

Original plain vanilla approach

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

Original plain vanilla approach

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

Ruby, 78

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

Ruby, 96

Original plain vanilla approach

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |
added 35 characters in body
Source Link
Level River St
  • 26.7k
  • 4
  • 37
  • 105

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

Original plain vanilla approach

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

Original plain vanilla approach

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |
added 255 characters in body
Source Link
Level River St
  • 26.7k
  • 4
  • 37
  • 105

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

#Ruby, 96#

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |

#Ruby, 78#

"@EHIKKIHE@".each_byte{|i|puts"+|"[i/65]+?X*(i-64)+" -"[i%3]*(98-i)+"|+"[i%3]}

A copy of Rinkattendant's / Xnor's idea of iterating over the lengths of the strings of X's. Except instead of using an array, I have compressed them into a string.

#Ruby, 96#

(0..9).each{|i|puts (i%9<1??+:?|)+(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])+"+||"[i%3]}

Ungolfed

(0..9).each{|i|
   puts (i%9<1??+:?|)                                          #first character + or |
   +(?X*("@EHIKKIHE@"[i].ord-64)).ljust(34,"-  "[i%3])         #print quantity of X's according to string, then right justify with - or space
   +"+||"[i%3]}                                                #last character + or |
added 369 characters in body
Source Link
Level River St
  • 26.7k
  • 4
  • 37
  • 105
Loading
Source Link
Level River St
  • 26.7k
  • 4
  • 37
  • 105
Loading