adam12 changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.0.2, 2.7.4, 2.6.8: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://goo.gl/wpGhoQ
sagax has quit [Remote host closed the connection]
gggpkm has quit [Remote host closed the connection]
gggpkm has joined #ruby
ur5us has joined #ruby
roshanavand has joined #ruby
RougeR has quit [Ping timeout: 252 seconds]
jetchisel has joined #ruby
roshanavand has quit [Ping timeout: 268 seconds]
Rounin has quit [Ping timeout: 245 seconds]
brw has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
SteveR has joined #ruby
SteveR has quit [Client Quit]
zph1nx has joined #ruby
zph1nx has left #ruby [#ruby]
_ht has joined #ruby
ur5us has quit [Ping timeout: 252 seconds]
mrkz_c has quit [Quit: Connection closed for inactivity]
krishnac has joined #ruby
krishnac has quit [Remote host closed the connection]
_ht has quit [Remote host closed the connection]
krishnac has joined #ruby
krishnac has quit [Remote host closed the connection]
krishnac has joined #ruby
krishnac has quit [Remote host closed the connection]
krishnac has joined #ruby
krishnac has quit [Remote host closed the connection]
gggpkm has quit [Remote host closed the connection]
tbaeder has joined #ruby
teclator has joined #ruby
ur5us has joined #ruby
gr33n7007h has quit [Quit: WeeChat 3.3]
rhe1 has joined #ruby
weaksauce has quit [Read error: Connection reset by peer]
rhe has quit [Quit: Ping timeout (120 seconds)]
rhe1 is now known as rhe
Oxfuxxx_ has joined #ruby
sharkee has joined #ruby
VoidNoir0 has quit [Quit: Ping timeout (120 seconds)]
ur5us_ has joined #ruby
ur5us has quit [Read error: Connection reset by peer]
roshanavand has joined #ruby
pwnd_sfw has quit [Quit: Ping timeout (120 seconds)]
gggpkm has joined #ruby
pwnd_sfw has joined #ruby
roshanavand has quit [Ping timeout: 264 seconds]
gggpkm has quit [Remote host closed the connection]
tkonto has joined #ruby
Rounin has joined #ruby
lunarkitty has joined #ruby
sagax has joined #ruby
taupiqueur has joined #ruby
ferr_ has quit [*.net *.split]
weyhmueller_ has quit [*.net *.split]
dostoyevsky2 has quit [*.net *.split]
Aighearach has quit [*.net *.split]
jimeh has quit [*.net *.split]
justache has quit [*.net *.split]
nowaker_ has quit [*.net *.split]
Artea has quit [*.net *.split]
jhawthorn has quit [*.net *.split]
swaggboi has quit [*.net *.split]
benjaminwil has quit [*.net *.split]
ur5us_ has quit [Ping timeout: 264 seconds]
tkonto has quit [Quit: tkonto]
swaggboi has joined #ruby
jimeh has joined #ruby
Artea has joined #ruby
Aighearach has joined #ruby
weyhmueller_ has joined #ruby
justache has joined #ruby
jhawthorn has joined #ruby
dostoyevsky2 has joined #ruby
benjaminwil has joined #ruby
nowaker_ has joined #ruby
ferr_ has joined #ruby
justache has quit [Max SendQ exceeded]
justache has joined #ruby
Oxfuxxx_ has quit [Quit: Never underestimate the power of the butt.[]OX/...ON. (Playst...i mean.. Pir@tA$$)]
shark_JQI has joined #ruby
shark_JQI has quit [Remote host closed the connection]
sharkee has quit [Ping timeout: 245 seconds]
sharkee has joined #ruby
Oxfuxxx_ has joined #ruby
Oxfuxxx has quit [Quit: leaving]
Oxfuxxx_ is now known as Oxfuxxx
unmanbearpig has joined #ruby
sharkee has quit [Remote host closed the connection]
sharkee has joined #ruby
Oxfuxxx has quit [Quit: Never underestimate the power of the butt.[]OX/...ON. (Playst...i mean.. Pir@tA$$)]
sharkee has quit [Remote host closed the connection]
sharkee has joined #ruby
Oxfuxxx has joined #ruby
Oxfuxxx is now known as artemis
artemis is now known as Oxfuxxx
taupiqueur has quit [Ping timeout: 245 seconds]
taupiqueur has joined #ruby
Oxfuxxx is now known as artemis
artemis is now known as Oxfuxxx
Oxfuxxx is now known as artemis
artemis is now known as Oxfuxxx
forvelin has quit [Ping timeout: 268 seconds]
lunarkitty has quit [Quit: Connection closed for inactivity]
shark_DXK has joined #ruby
shark_IWN has joined #ruby
sharkee has quit [Ping timeout: 250 seconds]
Oxfuxxx has quit [Ping timeout: 245 seconds]
shark_DXK has quit [Ping timeout: 264 seconds]
Oxfuxxx has joined #ruby
darkstarx has quit [Ping timeout: 250 seconds]
Oxfuxxx has quit [Client Quit]
shark_IWN has quit [Remote host closed the connection]
darkstardevx has joined #ruby
gggpkm has joined #ruby
sharkee has joined #ruby
Oxfuxxx has joined #ruby
taupiqueur has quit [Remote host closed the connection]
taupiqueur has joined #ruby
forvelin has joined #ruby
goepsilongo has joined #ruby
RougeR has joined #ruby
shark_BRY has joined #ruby
sharkee has quit [Ping timeout: 252 seconds]
Oxfuxxx has quit [Ping timeout: 268 seconds]
Oxfuxxx has joined #ruby
Oxfuxxx has quit [Ping timeout: 245 seconds]
shark_BRY has quit [Ping timeout: 245 seconds]
bit4bit has joined #ruby
factor6 has joined #ruby
factor has quit [Ping timeout: 250 seconds]
factor6 is now known as factor
jmcgnh has quit [Ping timeout: 265 seconds]
jmcgnh has joined #ruby
Rounin has quit [Ping timeout: 264 seconds]
krishnac has joined #ruby
_ht has joined #ruby
krishnac has quit [Ping timeout: 250 seconds]
SuperLag has quit [Ping timeout: 245 seconds]
SuperLag has joined #ruby
gggpkm has quit [Ping timeout: 245 seconds]
tkonto has joined #ruby
tbaeder has quit [Ping timeout: 268 seconds]
FetidToot7 has joined #ruby
FetidToot has quit [Ping timeout: 260 seconds]
FetidToot7 has quit [Client Quit]
FetidToot has joined #ruby
FetidToot7 has joined #ruby
FetidToot has quit [Ping timeout: 245 seconds]
FetidToot7 is now known as FetidToot
krishnac has joined #ruby
krishnac has quit [Remote host closed the connection]
Oxfuxxx has joined #ruby
dviola has joined #ruby
taupiqueur has quit [Remote host closed the connection]
taupiqueur has joined #ruby
tkonto has quit [Quit: tkonto]
tkonto has joined #ruby
bit4bit has quit [Ping timeout: 264 seconds]
bit4bit has joined #ruby
weaksauce has joined #ruby
Oxfuxxx has quit [Ping timeout: 246 seconds]
Oxfuxxx has joined #ruby
Rounin has joined #ruby
tkonto has quit [Quit: tkonto]
tkonto has joined #ruby
howdoi has joined #ruby
goldfish has joined #ruby
jpw has quit [Remote host closed the connection]
AMPed has joined #ruby
<AMPed> I just saw this in some code I'm working on: range = [*'1'..'9',*'A'..'N',*'P'..'Z',*'a'..'n',*'p'..'z']
<adam12> Heh.
<adam12> Can't have no 0's or O's
<AMPed> I see that the asterisks ensure that these become actual ranges, but I've never seen that before. What is this construct named, and where can I find documentation on it?
pgib has joined #ruby
<adam12> The * is a splat
<AMPed> Why splat there?
<adam12> because if not, you have an Array of Ranges, not an Array of Arrays.
<adam12> actually, you'd have an Array of Characters.
<adam12> vs an Array of Ranges.
<AMPed> Do we know where this is documented? I looked at https://ruby-doc.org/core-3.0.2/Range.html, but didn't see anything like it.
<adam12> AMPed: Which part?
<AMPed> The part where the splat turns a Range into an Array of Characters.
<adam12> I'm not sure if the splat is documented anywhere.
<adam12> basically *something calls something.to_ary. Range responds to to_ary which is how the implicit conversion works.
<AMPed> adam12: cool, thanks. Is this a common construct? I'm nobody's expert in anything, but I've never seen it before.
skryking has joined #ruby
Oxfuxxx has quit [Ping timeout: 245 seconds]
_ht has quit [Remote host closed the connection]
<AMPed> adam12: I think I'll dig into intricacies of the splat operator later, at my leisure. Thanks!
<adam12> AMPed: Splatting like that is common but maybe verbose.
<AMPed> got it
<adam12> I'd generate the entire subset and eliminate the unwanted ones afterwards. range = [*?A..?Z, *?a..?z, *0..9] - ["O", 0]
<adam12> Or use `SecureRandom.alphanumeric` if this is being used for what I think it's being used for.
<adam12> Ah. There's the splat docs: https://docs.ruby-lang.org/en/2.0.0/syntax/assignment_rdoc.html#label-Implicit+Array+Assignment
<AMPed> adam12: thanks; although that document's definition of "left-hand side" and mine are different, unless I'm misreading it.
<adam12> AMPed: Does it mention left-hand? I didn't see it.
ur5us_ has joined #ruby
<AMPed> adam12: "You can splat anywhere in the left-hand side of the assignment:
<AMPed> a = 1, *[2, 3]; p a # prints [1, 2, 3]"
<adam12> Right hand side?
<AMPed> that's what I would have thought.
<adam12> That's what it says tho, no?
<adam12> You can splat anywhere in the right-hand side of the assignment:
<AMPed> it says left
<AMPed> and the next two examples use left-hand where I'd use right-hand. Maybe it's because the page is facing the opposite direction from me :)
<adam12> oh lol maybe.
skryking has quit [Quit: Konversation terminated!]
trillp has joined #ruby
AMPed has quit [Quit: Thanks, going to lunch now!]
lunarkitty has joined #ruby
justache is now known as justHaunt
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
Skyfire has quit [Quit: WeeChat 3.3]
Skyfire has joined #ruby
tkonto has quit [Quit: tkonto]
tkonto has joined #ruby
bit4bit has quit [Remote host closed the connection]
tkonto has quit [Client Quit]
tkonto has joined #ruby
bit4bit has joined #ruby
cyrus_mc has joined #ruby
tkonto has quit [Quit: tkonto]
Byteflux has quit [Quit: ZNC - https://znc.in]
bit4bit has quit [Remote host closed the connection]
Byteflux has joined #ruby
cyrus_mc has quit [Quit: Connection closed]
mrkz_c has joined #ruby
lunarkitty has quit [Quit: Connection closed for inactivity]
ur5us_ has quit [Ping timeout: 250 seconds]
taupiqueur has quit [Ping timeout: 250 seconds]
goepsilongo has quit [Quit: Konversation terminated!]
Oxfuxxx has joined #ruby
Oxfuxxx has quit [Quit: Never underestimate the power of the butt.[]OX/...ON. (Playst...i mean.. Pir@tA$$)]
Pixi has joined #ruby
<donofrio> anyone have a quick learn ruby site/video?