#voice-chat-text-1

1 messages Β· Page 79 of 1

gray marlin
misty sinew
#

ok guys
I will take your leave

bye

whole finch
#

Bye AG

misty sinew
#

no goodbyes :c

gray marlin
#

i dont

peak frigate
misty sinew
#

bye @whole finch πŸ‘‹

gray marlin
#

bye AG

whole finch
#

Contacts make me look better

twin locust
#

hey

gray marlin
twin locust
#

need help installing apache spark for jupyter notebooks

unique raptor
gray marlin
gray marlin
#

who is hammering keyboard

whole finch
#

we can always count on kemal for the funny jokes

peak frigate
#

noiceeeeeee

gray marlin
#

call me = ||911 ||

warm tendon
#

πŸ‘€ an actual typeracer account? @peak frigate πŸ‘€

peak frigate
#

needed bc if you do well they'll suspect fraud and test you again

warm tendon
#

fair enough

#

i just do the test evry tiem

whole finch
#

I never learned how to type properly

#

I dont use all 10 fingers and I dont use homerow

warm tendon
#

πŸ˜”

whole finch
#

I use like 3 or 4 fingers and still get 90-120 wpm so...

warm tendon
#

(x)

knotty solar
#

I make lot of mistakes while typing
now my correction speed is fast
but still make mistakes

gray marlin
unique raptor
#

my password

#

maker

gray marlin
knotty solar
#

What was she making? πŸ˜‚ Simone Giertz

#

I watched her ted talk

gray marlin
#

lmao

knotty solar
#

like seriously what is she trying to create in that gif?

gray marlin
#

recaptcha

knotty solar
#

maybe a robot hand to slam faces on keyboards

#

for bosses

#

in work env

gray marlin
#

made out of spaghetti

knotty solar
#

oh, why Hemlock shave his head?

warm tendon
#

πŸ€”

knotty solar
#

you're married right?

gray marlin
#

same hemlock

knotty solar
#

wife okay with that?

#

hmm

#

πŸ˜‚ okay

gray marlin
#

XD

raw wren
gray marlin
raw wren
#

thats my really curly hair ^^^

whole finch
#

cool

gray marlin
#

nice

knotty solar
#

hmm, shampoo I guess, once in a while

golden marsh
gray marlin
#

niceee

warm tendon
#

@crisp pollen your keyboard is very loud

crisp pollen
#

ty

warm tendon
#

that was not a compliment...

crisp pollen
#

ok

twin locust
#

xddx

whole finch
#

long hair pog

knotty solar
#

ok, now this is all Wookie pics

gray marlin
#

lmao

crisp pollen
#

what

#

what about me

mint isle
#

yup

golden marsh
#

you got keyboard noises coming throuhg @crisp pollen

warm tendon
knotty solar
#

Rabbit's has a Surface

mint isle
#

wow this is lot of static charge

crisp pollen
#

I just turned noise suppresion on

gray marlin
whole finch
unique raptor
#

Roast my pc

whole finch
#

^ in my old room without windows

gray marlin
#

oooo rgb

mint isle
whole finch
mint isle
#

yep

gray marlin
#

my hair

whole finch
#

I could set it to pink instead

knotty solar
#

yeah, for laptop's info checkout DaveLee on youtube

gray marlin
#

shiny af

mild flume
raw wren
whole finch
gray marlin
unique raptor
whole finch
#

But I recommend zip ties ℒ️

golden marsh
#

@crisp pollen thats honestly not too bad, mine is WAY worse

mint isle
unique raptor
whole finch
#

Actually not bad

mint isle
#

thats still bad

gray marlin
unique raptor
#

yes road

knotty solar
#

my custom terminal 😏

unique raptor
#

WEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEB

whole finch
unborn prairie
#

broooooooooo

mild flume
#

Let people enjoy what they want to enjoy

unborn prairie
open sedge
#

japanese cartoon terminal

knotty solar
#

no no I am weeb

mint isle
#

lol ... terminals should be like terminal

#

thats a mess

golden marsh
#

thats not even from a anime

knotty solar
#

yeah

mint isle
#

unnecessary incoming information

golden marsh
#

its from a series produced in texas

unborn prairie
knotty solar
#

that's just ||hot||||af||

#

it makes me want to use it more and more

mint isle
open sedge
#

Roles

unique raptor
#

he is special

golden marsh
knotty solar
#

one tweak, now its back

peak frigate
# raw wren

jake!!!!!!!!!!!!!!!! it's so crooked!!!!!!!!!!!!!!!

mint isle
#

i need my name to be blue color

knotty solar
#

there's some brown text behind my terminal, so its brown rn

#

better than blue

mint isle
#

why do they come up with these advertisements ... ?

#

lol would you put up acid on your face

peak frigate
#

what's wrong with hyaluronic acid?

#

it's a very good skincare ingredient

#

binds with water

#

result is nice and plump skin πŸ™‚

gray marlin
peak frigate
#

did your know, the surface of your skin is acidic?

gray marlin
#

hyla oula oula

peak frigate
#

you should use products with an approximate pH of 5.5 so as not to strip your acid mantle

knotty solar
#

surface of my skin is acne

open sedge
mint isle
#

lets talk bout skin care

peak frigate
#

and most foaming/bar soaps have a high pH and will compromise that acid mantle

raw wren
mild flume
peak frigate
mild flume
#

But not that lemon

open sedge
peak frigate
#

noOOOOOOOooOoo lemons lol

mild flume
peak frigate
#

the goal is not to go as acidic as possible lol

knotty solar
#

I workout a lot, so my biological age actually reverses
so I an stuck in my teen
that's why acne won't go
that's what I tell myself

open sedge
gray marlin
mint isle
#

now thats some talk mina

knotty solar
#

he definitely push when he makes crappy jokes

peak frigate
#

lol do NOT put lemons on your skin

mint isle
#

hayala acid

knotty solar
#

I put'em in my teeth, lemons + baking soda

mint isle
#

hayamoronic acid

gray marlin
#

nitric acid

mint isle
#

thats best for skin

unique raptor
gray marlin
knotty solar
#

moronichayastupidonic acid

mint isle
#

once they offered me the admin role ... but then i denied it... πŸ˜•

knotty solar
#

wise decision

raw wren
peak frigate
#

^ ty

warm tendon
warm tendon
#

that's you right?

open sedge
#

Soap is ph 10 so its good to eat πŸ™‚

warm tendon
#

uhhhh

mint isle
#

LOND MO

unborn prairie
#

seems familiar

peak frigate
#

vixx, ravi

knotty solar
#

I think, Johnson's & Johnson's soap might be edible

unborn prairie
mint isle
#

are you guys wearing masks ... or slacked it

open sedge
warm tendon
#

well yeah

peak frigate
#

.............

unborn prairie
#

just why

knotty solar
open sedge
unborn prairie
#

ok fair

#

that sounds reasonable

knotty solar
#

I've eaten brick crumble, when It rained
it smelled good
I was 4 or 5

open sedge
mint isle
#

olive oil

#

mustard

#

almond

#

avacado πŸ₯‘

#

kewl

knotty solar
#

ok, I'm gonna take a 5 at the roof, breeze's nice, gonna pause & ponder
trying to be cheezy

#

can't follow up the convo
don't cook myself

mild flume
#

I'm incredibly ashamed of myself

open sedge
#

?

mild flume
#

It took me 2 to 3 minutes to find the power button on this new laptop

knotty solar
mild flume
#

Har dee har

knotty solar
#

@elder wraith your opinion/views on Surface laptop?

mint isle
#

surface laptop ... are for noobs

knotty solar
#

maybe after MasterChef's over

mild flume
#

I've never ever seen a power button there

#

Ever

mint isle
#

thats bad design

unborn prairie
mild flume
#

I don't think I can be faulted for me not finding it initially

unborn prairie
#

yeah

#

thats a weird ass positon

mint isle
#

may be its made for some diff country

elder wraith
knotty solar
#

maybe they just made it right over the button on the motherboard

elder wraith
#

However getting Linux running on it is annoying so I wouldn’t get one if you intend to run Linux natively

knotty solar
#

@raw wren were you asking about Surface pro earlier?

elder wraith
#

WSL works fine though

knotty solar
#

WSL2

#

jinx

royal saffron
#

oh I am going to delete this comma ... oh shit here we go again. I have to retype my whole doc cause ... I shutdown my laptop

elder wraith
royal saffron
#

the one from the army ?

elder wraith
#

Hemlock, you can disable the button

mild flume
#

I'm not touching it until I know what my boss wants with it

elder wraith
#

Power Options

knotty solar
#

why do people in this chat know so much about utensils, dish soaps etc?

mild flume
#

She's already really really really really unhappy with the rollout of this laptop for her

golden marsh
#
elder wraith
#

My guess is she’s unhappy that’s not her old laptop

knotty solar
#

the only thing a coder worry about in new laptops is how's the keyboard layout
other stuff is just nitpicking/bitching

peak frigate
#

^ the answer is an external custom keyboard :^)

knotty solar
#

yeah, so no sense at all

#

just the screen

peak frigate
#

i don't think i could ever go back to daily laptop use

warm tendon
knotty solar
#

me niether

elder wraith
#

Surface Laptops are great daily drivers

peak frigate
#

lol what are you using an IBM buckling spring??

warm tendon
#

uh

#

corsair k70 lol, it's fullsize

knotty solar
#

oh, I have a fix for it

#

hang on

elder wraith
warm tendon
#

it's so bland

knotty solar
#

when you go from desktop back to laptop

peak frigate
#

lol

whole finch
#

Lol

#

Kinda true

knotty solar
#

ooof, mom again

#

brb

unborn prairie
whole finch
#

when I got my monitor, it fucking hurt my eyes because I was so used to the tiny laptop screen that it seemed massive

peak frigate
#

please sane email!

#

no skpe!

open sedge
#

yes.

whole finch
#

Lol

elder wraith
unborn prairie
open sedge
elder wraith
#

Wasn't aware it was still kicking

peak frigate
#

this is from another employee lol

finite garden
#

now you corrected

peak frigate
#

there's a cute skype easter egg

#

of a dancing monkey

unborn prairie
#

still love the discord 404 easter egg

warm tendon
#

πŸ˜”

#

πŸ‘€

peak frigate
narrow terrace
#

can't quite hear you

warm tendon
#

why isn't fix server muted

#

@ moderators

narrow terrace
#

because it's always causing disruption here!

warm tendon
#

D:

narrow terrace
#

"why are you server-muted" x10

warm tendon
#

now it is causing even more!

narrow terrace
#

is that BTS @golden marsh?

warm tendon
#

@peak frigate ||stan loona||

narrow terrace
#

πŸ™‚

golden marsh
warm tendon
#

behind the scenes

golden marsh
#

context?

mild flume
open sedge
#

behind the Scenes?

#

is that what BTS stands for?

mild flume
#

BTS == Big Taco Stand

finite garden
#

I love korean prank videos , lol

olive ravine
narrow terrace
narrow terrace
open sedge
#

oh BTS is a band

golden marsh
#

i am confusion

olive ravine
#

I cannot stop laughing at bananarotat_SPEED, btw

narrow terrace
#

or Rust πŸ™‚

#

by data-drivenoriented you mean 'operate on a row of arrays' instead of 'operate on an array of rows'? πŸ™‚

tiny pumice
#

Evenin'

narrow terrace
#

But you could do OO with static dispatch, right @golden marsh?

#

(in C++, that is, not in e.g. Python)

#

well, yeah, the "'operate on a row of arrays' instead of 'operate on an array of rows'" part

#

because of cache locality and crap

#

Maybe https://en.wikipedia.org/wiki/Memory_access_pattern will help. Basically, accessing data one-by-one directly in memory is pretty slow; and if you follow pointers (like in a linked list), it's even worse -- with slowdowns of 10x or more. That's because of CPU caches.

#

@mild flume

golden marsh
narrow terrace
#

so

[(1, 2, 3, 4), (5, 6, 7, 8), (9, 10, 11, 12), ...]

or

[(1, 2, *, 4), (5, 6, *, 8), (9, 10, *, 12), ...]
        |             |              |
        V             V              V
        3             7             11

is generally worse for performance than

[1, 5, 9]
[2, 6, 10]
[3, 7, 11]
[4, 8, 12]
...
#

@golden marsh can you give a link? I'm intrigued

golden marsh
#

sure 1 sec

wintry sinew
#
def SplitText ( sentence , delimiter ) :  # Yes, *that* kind of camel case
        letters = list ()  # Apparently it's "more efficient to define it as a list and then set the values"
        words = list ()
        letters = [ *list ( sentence ) ]  # The formatting hurts but you get used to it... eventually

        temporary_variable_word = str ()  # Temp vars "should start with temporary_variable_"
        done = bool ()
        done = False

        counter = int ()
        counter = 0
        while done == False :
                if letters[ counter ] == delimiter :
                        if len ( temporary_variable_word ) != 0 :
                                words = [ *words, *[ temporary_variable_word ] ]
                        temporary_variable_word = str ()
                else :
                        temporary_variable_word = temporary_variable_word + letters[ counter ]

                counter = counter + 1

                if counter == len ( sentence ) :
                        done = True

        if len ( temporary_variable_word ) != 0 :
                words = [ *words, *[ temporary_variable_word ] ]

        return words```
tiny pumice
#

Re: Paradigms
I guess I can argue that paradigms themselves still influence how you solve problems with a language, considering that it's the nature of said language; on the other hand, stuff like design patterns a lá Gang of Four, or abstractions e.g. coroutines as fancy wrappers over generators, can totally be avoided.

narrow terrace
#
letters = list ()  # Apparently it's "more efficient to define it as a list and then set the values"

what the fucking

#

...fuck

warm tendon
#

lol what

tiny pumice
#
words = [ *words, *[ temporary_variable_word ] ]
narrow terrace
#

what theeee

words = [ *words, *[ temporary_variable_word ] ]
tiny pumice
#

why

warm tendon
#

wtf is that

unborn prairie
#
print("\n".join((aaa := lambda x, run: (("FizzBuzz" if not x % 15 else "Fizz" if not x % 3 else "Buzz" if not x % 5 else f"{x}"), *aaa(x+1, run)) if x <= run else "")(1, int(input(">")))))```
golden marsh
narrow terrace
elder wraith
#

Did you know a = list() is slower then a = []

raw wren
#

Hey, if someone could hop into code help 0 that would be great I keep getting this silly error but I have no clue how to fix it, I am trying to setup a help command with reactions on the bottom that you can click and it changes the page

warm tendon
elder wraith
#

!e python import timeit print(timeit.timeit('a = list()')) print(timeit.timeit('a = []'))

coarse hearthBOT
#

@elder wraith :white_check_mark: Your eval job has completed with return code 0.

001 | 0.2332251900807023
002 | 0.06519375601783395
warm tendon
#

wtf

#

i guess that makes sense

elder wraith
#

dict is same way

narrow terrace
elder wraith
#

!e python import timeit print(timeit.timeit('a = dict()')) print(timeit.timeit('a = {}'))

coarse hearthBOT
#

@elder wraith :white_check_mark: Your eval job has completed with return code 0.

001 | 0.22611023113131523
002 | 0.0853405250236392
narrow terrace
#

@mild flume well, you have Optional in the typehint land

warm tendon
#

but no optional type πŸ˜”

narrow terrace
#

@golden marsh have you seen:

#

!pypi dataclass_factory

coarse hearthBOT
#
Author

A. Tikhonov

Requires Python

=3.6

Summary

An utility class for creating instances of dataclasses

License

Apache2

narrow terrace
#

@golden marsh wdym?

#

I don't get what you're saying about list/sequence

golden marsh
#

!e ```py
from typing import List, Sequence

print(isinstance(List[int], Sequence))

coarse hearthBOT
#

@golden marsh :white_check_mark: Your eval job has completed with return code 0.

False
golden marsh
#

😒

narrow terrace
#

!e

from typing import List, Sequence

print(issubclass(List[int], Sequence))
coarse hearthBOT
#

@narrow terrace :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 3, in <module>
003 |   File "/usr/local/lib/python3.9/typing.py", line 830, in __subclasscheck__
004 |     return super().__subclasscheck__(cls)
005 |   File "/usr/local/lib/python3.9/typing.py", line 700, in __subclasscheck__
006 |     raise TypeError("Subscripted generics cannot be used with"
007 | TypeError: Subscripted generics cannot be used with class and instance checks
narrow terrace
#

uhhhh

#

hmmm

golden marsh
#

see

#

SEEE

#

its AWFULL

narrow terrace
#

Why would you ever want that?

warm tendon
#

why is that useful though

golden marsh
#

you cant even use typing.get_origin because the origin of List is list but the origin of Sequence is none

warm tendon
#

or why would that be useful

narrow terrace
#

!e

from typing import List, Sequence

print(issubclass(List[int].__origin__, Sequence))
coarse hearthBOT
#

@narrow terrace :white_check_mark: Your eval job has completed with return code 0.

True
narrow terrace
#

see

#

or typing.get_origin or whatever

golden marsh
#

!e ```py
from typing import Dict, Mapping

print(issubclass(Dict[int, int].origin, Mapping))

coarse hearthBOT
#

@golden marsh :white_check_mark: Your eval job has completed with return code 0.

True
narrow terrace
#

but why do you need that?

golden marsh
#

huh

#

wait

#

what

narrow terrace
#

you used isinstance instead of issubclass @golden marsh

#

the first time

golden marsh
#

right but one sec

narrow terrace
#

alright, I have to go now, I need to stop procrastinating on my project

golden marsh
#

why did that not work 2h ago?

#

im 100% sure i tried that

gentle flume
#

@mild flume are you using a laptop with your three monitors?

mild flume
#

Like as well as?

#

And I guess technically

#

I've got my current computer on one screen, the new one that I'm scooting stuff to on another, and had a co-worker's computer on the third

#

And then I do have a laptop far left of me what's being remoted into by our IT folks

golden marsh
#

as for why: user makes dataclass annotated with either a list or a tuple or another sequence, and i need to handle all of those in my code. so the thing that makes the most sense is to check whether the annotations are sequence types

narrow terrace
#

!pypi dataclass_factory

coarse hearthBOT
#
Author

A. Tikhonov

Requires Python

=3.6

Summary

An utility class for creating instances of dataclasses

License

Apache2

narrow terrace
#

it's like pydantic, but for native dataclasses

#

Although no, it doesn't support Sequence as an annotation. But you could use Union[List[T], Tuple[T, ...]] or something like that, I guess

golden marsh
#

does it properly resolve nested dataclasses in Dicts?

#

as in

#

Dict[int, MyDataclass]

narrow terrace
#

Yes. Doesn't even dataclasses.asdict do that?

golden marsh
#

i mean, the other way around

#

creating dataclass instance from a dict

narrow terrace
#

yeah, it goes both ways

golden marsh
#

at least base dataclasses dont do that (nicely)

#

lemme test

#

the factory

misty sinew
#

Hi everyone

narrow terrace
#

@golden marsh It's a bit unpolished in some places now, but for most use cases it's okay, I guess.

#

it supports stuff like renaming camelcased names and such

golden marsh
#

does it have a sort of "Any" type catchall for unstructured data or as a temporary droping for unimplementd models? @narrow terrace

mild flume
#

Typing does have an Any, yeah

golden marsh
stuck bluff
#

For the record, the tea was a lie.

wintry sinew
narrow terrace
#

just acts as an identity function

#

i.e. just passes in the JSON dict

#

or not dict

lime grove
#

@warm tendon no physics?

warm tendon
#

what about you dummy

lime grove
#

i'm not in vc :P

pearl torrent
raw wren
#
        message = await ctx.send(embed=embed)

        await message.add_reaction(emoji='813820542389977099')

@charred creek

charred creek
#

813820542389977099

raw wren
#

◀️ \

charred creek
#

\

raw wren
#

\◀️

charred creek
#
        message = await ctx.send(embed=embed)

        await message.add_reaction("◀️")
raw wren
#

await message.add_reaction(emoji='◀️')

#
Ignoring exception in command help:
Traceback (most recent call last):
  File "D:\Discord-Bot\venv\lib\site-packages\discord\ext\commands\core.py", line 85, in wrapped
    ret = await coro(*args, **kwargs)
  File "C:\Users\jakea\Desktop\Verification Bot\cogs\help.py", line 23, in help
    await message.add_reaction(emoji=':arrow_backward:')
  File "D:\Discord-Bot\venv\lib\site-packages\discord\message.py", line 1149, in add_reaction
    await self._state.http.add_reaction(self.channel.id, self.id, emoji)
  File "D:\Discord-Bot\venv\lib\site-packages\discord\http.py", line 247, in request
    raise HTTPException(r, data)
discord.errors.HTTPException: 400 Bad Request (error code: 10014): Unknown Emoji

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "D:\Discord-Bot\venv\lib\site-packages\discord\ext\commands\bot.py", line 902, in invoke
    await ctx.command.invoke(ctx)
  File "D:\Discord-Bot\venv\lib\site-packages\discord\ext\commands\core.py", line 864, in invoke
    await injected(*ctx.args, **ctx.kwargs)
  File "D:\Discord-Bot\venv\lib\site-packages\discord\ext\commands\core.py", line 94, in wrapped
    raise CommandInvokeError(exc) from exc
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: HTTPException: 400 Bad Request (error code: 10014): Unknown Emoji
round pecan
#

hello guys

charred creek
#

\❌

round pecan
#

you guys making discord bot too

#

ill make one but its not working

charred creek
#

oof

round pecan
#

its want programm to work to be online you know

#

heres my bot ill send you now

charred creek
round pecan
#

here

charred creek
#

there

round pecan
#

i cant send the link

#

lol

charred creek
#

link no send here you cannot

round pecan
#

ok

raw wren
#
        def check(reaction, user):
            return user == ctx.author and str(reaction.emoji) in [backward, forward]

        while True:
            try:
                reaction, user = ctx.wait_for('reaction_add', timeout=60, check=check)

                if str(reaction.emoji) == '▢️' and cur_page != pages:
                   cur_page += 1
                    await message.edit(content=f'Page {cur_page}/{pages}:\n{contents[cur_page-1]}')
                    await message.remove_reactions(reaction, user)

                elif str(reaction.emoji) == "◀️" and cur_page > 1:
                    cur_page -= 1
                    await message.edit(content=f"Page {cur_page}/{pages}:\n{contents[cur_page - 1]}")
                    await message.remove_reaction(reaction, user)

                else:
                    await message.remove_reaction(reaction, user)
                await message.delete()
                break
tribal glen
#
if cursor.fetchone()[0] == 0:
#
    @commands.command()
    async def db(self, ctx, message):
        db = sqlite3.connect('main.sqlite')
        cursor = db.cursor()
        cursor.execute(f"SELECT cmd, respons FROM main WHERE guild_id = {ctx.guild.id}")
        result = cursor.fetchone()[]
#
    @commands.command()
    async def db(self, ctx, message):
        db = sqlite3.connect('main.sqlite')
        cursor = db.cursor()
        cursor.execute("""SELECT cmd, respons FROM main WHERE guild_id = (?)
        """, (ctx.guild.id))
        result = cursor.fetchone()[]
twin locust
#

i can't figure it out how to run spark on jupyer notebook. Please help

charred creek
#
    @commands.command()
    async def db(self, ctx, message):
        db = sqlite3.connect('main.sqlite')
        cursor = db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (ctx.guild.id, message))
        await ctx.send(cursor.fetchone()[0])
tribal glen
random minnow
tribal glen
#
    @commands.Cog.listener()
    async def on_message(self, ctx, message):
        db = sqlite3.connect('main.sqlite')
        cursor = db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (ctx.guild.id, message))
        await ctx.send(cursor.fetchone()[0])
charred creek
#
 discord.on_message(message)
#
    @commands.Cog.listener()
    async def on_message(self, message):
        db = sqlite3.connect('main.sqlite')
        cursor = db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (message.guild.id, message.content))
        await message.channel.send(cursor.fetchone()[0])
tribal glen
#

=

#

!addcom test griff

#

test

#

griff

#

G RUFFF

charred creek
#

yike

tribal glen
#
    @commands.Cog.listener()
    async def on_message(self, message):
        cursor = self.db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (message.guild.id, message.content.lower))
        if message.author != self.bot.user:
            await message.channel.send(cursor.fetchone()[0])
#

!addcom !test griff smells

#

!test

#
discord.ext.commands.errors.CommandNotFound: Command "test" is not found
charred creek
#
@command.Cog.Comand.com.com.command()
async def runcom(self, ctx, *, command):
  # Get Cursor
  # Find value that matches the command
  # If command exists, send the command response
tribal glen
#

!addcom !test griff

#

!test

polar crescent
#
@client.event
async def on_command_error(ctx, error):
    if isinstance(error, commands.CommandNotFound):
        #your code here

tribal glen
#
    @commands.Cog.listener()
    async def on_message(self, message):
        cursor = self.db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (message.guild.id, message.content))
        if message.author != self.bot.user:
            await message.channel.send(cursor.fetchone()[0])
#

!test

#
discord.ext.commands.errors.CommandNotFound: Command "test" is not found
#

mine is local

#

pyautoGUI

random minnow
charred creek
#

^

#

@scarlet cedar

mellow kelp
#
# Python Guide

## Super Basics
### Variables
>#### variables are used to store data
>#### variables have two parts. label and data
>eg: `var = 0`

### Print function
>#### used to display data
>eg: `print(0)`

### Input function
>#### used to **get data** from user in a **string** form
>eg: `user_input = input()`

## Data Types
### Strings
>#### strings are text
eg: `string1 = 'foo'`
`string2 = "bar"`
twin locust
#

someone here has experience with jupyter notebook?

misty sinew
#

ayy furry

tribal glen
#

Griff you wanna join the fun call varlemKAPPA

charred creek
#

!e

from typing import List
import random

def every_number_gte_seven(arr: List[int]) -> bool:
    for i in arr:
        if i <= 7: return False

    return True

test = [random.randint(1, 10) for num in range(10)]
print(test)
print(every_number_gte_seven(test))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | [4, 7, 1, 1, 1, 10, 7, 9, 3, 4]
002 | False
charred creek
#
reaction, user = await client.wait_for('reaction_add', timeout=60.0, check=lambda reaction, user: user == ctx.author)
cursive rover
#

await msg.add_reaction(':one:')
        await msg.add_reaction(':two:')
        await msg.add_reaction(':three:')
        def check(reaction, user):
            return user == ctx.author 
        reaction, user = await bot.wait_for('reaction_add', timeout=60.0, check=check)```
tribal glen
#
if str(reaction) == 'πŸ‘':
  # do stuff
charred creek
#

!e

from typing import List
import random

def every_number_gte_seven(arr: List[int]) -> bool:
    return all(element > 7 for element in arr)

test = [random.randint(1, 10) for num in range(10)]
print(test)
print(every_number_gte_seven(test))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | [4, 7, 9, 8, 5, 6, 9, 9, 9, 5]
002 | False
charred creek
#

@random minnow ^

tribal glen
#

print(

#
print('Hello World')
charred creek
#

Hello World

tribal glen
#
if griff == 'bot':
  print('Walla')
charred creek
#

Wall-E

#

!e

print(False == False in [False])
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

True
tribal glen
#
    • = +
charred creek
#

!e

print((False == False) in [False])
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

False
tribal glen
#

!e

print(['', ''][all(not (x := "hello world") == (x := x.replace(x[3], "0", 1)) for _ in range(1))], x)
coarse hearthBOT
#

@tribal glen :white_check_mark: Your eval job has completed with return code 0.

 he0lo world
tribal glen
#
@client.event
async def on_command_error(ctx, error):
    if isinstance(error, commands.CommandNotFound):
        #your code here
charred creek
#

!

#

!e

_dict = {}
_dict[5.0] = "KJ"

print(_dict[5])
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

KJ
charred creek
#

!e

_dict = {}
_dict[float(5.01)] = "KJ"

print(_dict[5])
coarse hearthBOT
#

@charred creek :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 4, in <module>
003 | KeyError: 5
random minnow
charred creek
#
_dict = {}
_dict[5] = "KJ"

print(_dict[5+0j])
#

!e

_dict = {}
_dict[5] = "KJ"

print(_dict[5+0j])
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

KJ
tribal glen
#
@client.event
async def on_command_error(ctx, error):
    if isinstance(error, commands.CommandNotFound):
        #your code here
charred creek
#
def some_func():
    try:
        return 'from_try'
    finally:
        return 'from_finally'

print(some_func())
#

!e

def some_func():
    try:
        return 'from_try'
    finally:
        return 'from_finally'

print(some_func())
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

from_finally
tribal glen
#
async def addcom(self, ctx, the_command: str=None, *, command_respond: str=None):
charred creek
#

!e

array = [1, 8, 15]
print(list((x for x in array if array.count(x) > 0)))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

[1, 8, 15]
random minnow
#
print(f"You are {(age := input('How old are you? '))} years old")

eww wtf

charred creek
#

!e

from enum import Enum

class KJ(Enum):
  K = 0
  J = 1


print(KJ(0).name, KJ(1).name)
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

K J
tribal glen
#

!e

print('K J')
coarse hearthBOT
#

@tribal glen :white_check_mark: Your eval job has completed with return code 0.

K J
charred creek
#

!e

from enum import Enum

class KJ(Enum):
  K = 0
  J = 1


print(KJ.K.name, KJ.J.name)
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

K J
random minnow
#

!e

from enum import Enum

class KJ(Enum):
  K = 0
  J = 1


print(dir(KJ.K))
coarse hearthBOT
#

@random minnow :white_check_mark: Your eval job has completed with return code 0.

['__class__', '__doc__', '__module__', 'name', 'value']
charred creek
#

!e

from enum import Enum

class KJ(Enum):
  K = 0
  J = 1


print(dir(KJ))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

['J', 'K', '__class__', '__doc__', '__members__', '__module__']
#

Hey @misty sinew!

Uh-oh! It looks like your message got zapped by our spam filter. We currently don't allow .txt attachments, so here are some tips to help you travel safely:

β€’ If you attempted to send a message longer than 2000 characters, try shortening your message to fit within the character limit or use a pasting service (see below)

β€’ If you tried to show someone your code, you can use codeblocks
(run !code-blocks in #bot-commands for more information) or use a pasting service like:

https://paste.pythondiscord.com

misty sinew
#

!code

coarse hearthBOT
#

Here's how to format Python code on Discord:

```py
print('Hello world!')
```

These are backticks, not quotes. Check this out if you can't find the backtick key.

charred creek
#
try:
  bot.run("TOKEN HERE")
finally:
  ... # Close db
coarse hearthBOT
#

Hey @misty sinew!

Uh-oh! It looks like your message got zapped by our spam filter. We currently don't allow .txt attachments, so here are some tips to help you travel safely:

β€’ If you attempted to send a message longer than 2000 characters, try shortening your message to fit within the character limit or use a pasting service (see below)

β€’ If you tried to show someone your code, you can use codeblocks
(run !code-blocks in #bot-commands for more information) or use a pasting service like:

https://paste.pythondiscord.com

misty sinew
#

!code-block

coarse hearthBOT
#

Here's how to format Python code on Discord:

```py
print('Hello world!')
```

These are backticks, not quotes. Check this out if you can't find the backtick key.

charred creek
#

!paste

coarse hearthBOT
#

Pasting large amounts of code

If your code is too long to fit in a codeblock in discord, you can paste your code here:
https://paste.pydis.com/

After pasting your code, save it by clicking the floppy disk icon in the top right, or by typing ctrl + S. After doing that, the URL should change. Copy the URL and post it here so others can see it.

#

Hey @misty sinew!

Uh-oh! It looks like your message got zapped by our spam filter. We currently don't allow .txt attachments, so here are some tips to help you travel safely:

β€’ If you attempted to send a message longer than 2000 characters, try shortening your message to fit within the character limit or use a pasting service (see below)

β€’ If you tried to show someone your code, you can use codeblocks
(run !code-blocks in #bot-commands for more information) or use a pasting service like:

https://paste.pythondiscord.com

charred creek
#

!paste

tribal glen
#

!site

coarse hearthBOT
#
Command Help

!site
Can also use: s

Commands for getting info about our website.

Subcommands:

!site faq
Info about the site's FAQ page.
!site help
Info about the site's Getting Help page.
!site home
Info about the website itself.
!site resources
Info about the site's Resources page.
!site rules [rules]...
Provides a link to all rules or, if specified, displays specific rule(s).
!site tools
Info about the site's Tools page.

charred creek
misty sinew
tribal glen
charred creek
#

!e

print('something' is not None, 'something' is (not None))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | <string>:1: SyntaxWarning: "is not" with a literal. Did you mean "!="?
002 | <string>:1: SyntaxWarning: "is" with a literal. Did you mean "=="?
003 | True False
random minnow
#

print(f"You are {(age := input('How old are you? '))} years old")

charred creek
#

!e

print((x:=1))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

1
tribal glen
#
Ignoring exception in on_message
Traceback (most recent call last):
  File "C:\Users\pc\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 333, in _run_event
    await coro(*args, **kwargs)
  File "C:\Users\pc\Desktop\Custom commands\cogs\stuff.py", line 58, in on_message
    await message.channel.send(cursor.fetchone()[0])
TypeError: 'NoneType' object is not subscriptable
226782198508814336
#

@random minnow

#

@charred creek

#

@random minnow

#

@charred creek

#
    @commands.Cog.listener()
    async def on_message(self, message):
        cursor = self.db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (message.guild.id, message.content))
        if message.author != self.bot.user:
            await message.channel.send(cursor.fetchone()[0])

        else:
            print('NOPE')

        await self.bot.process_commands(message)
charred creek
#
    @commands.Cog.listener()
    async def on_message(self, message):
        cursor = self.db.cursor()
        cursor.execute("""
          SELECT respons
          FROM main 
          WHERE guild_id = (?) AND cmd = (?)
         """, (message.guild.id, message.content))

        if not(result := cursor.fetchone()):
          return await message.channel.send("GET OUT OF MY SWAMP")
        elif message.author != self.bot.user:
            await message.channel.send(result[0])
        else:
            print('NOPE')

        await self.bot.process_commands(message)
tribal glen
#
# RANDOM SHIT FOR BETTER LIFE EXPERIENCE


    @commands.command()
    async def ip(self, ctx):
        id = ctx.author.id
        print(id)
random minnow
tribal glen
random minnow
#
hashlib.blake2b(data=b'', *, digest_size=64, key=b'', salt=b'', person=b'', fanout=1, depth=1, leaf_size=0, node_offset=0, node_depth=0, inner_size=0, last_node=False, usedforsecurity=True)
tribal glen
#
    @commands.command()
    async def ip(self, ctx, person: discord.Member):

        print(person.id)
#

Im gOnNa dDoS eVeRy ONE

charred creek
#

!e

import random
random.seed(107226564030156800)
print(f"Your IP: {random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}")
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

Your IP: 118.66.241.36.206
charred creek
#

!e

import random
random.seed(226782198508814336)
print(f"Your IP: {random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}.{random.randint(1,255)}")
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

Your IP: 122.74.253.14
tribal glen
misty sinew
tribal glen
#

    @commands.command()
    async def ip(self, ctx, person: discord.Member):
        random.seed(person.id)
#
        await ctx.send(embed=Embed(description=f"{person.display_name}'s IP: {random.randint(1, 255)}.{random.randint(1, 255)}.{random.randint(1, 255)}.{random.randint(1, 255)}", colour=discord.Colour.green()))
random minnow
#
#include <iostream>

struct Y{
  unsigned int x = 10;
};

int main(){
  Y z;
  std::cout<<z.x;
} 

the same as

#include <iostream>

class Y{
public:
  unsigned int x = 10;
};

int main(){
  Y z;
  std::cout<<z.x;
}
red gust
#

i keep typingthe !verify thing and right now it keeps getting me the error

misty sinew
#

πŸ˜‚

#

!e

coarse hearthBOT
#
Command Help

!eval [code]
Can also use: e

*Run Python code and get the results.

This command supports multiple lines of code, including code wrapped inside a formatted code
block. Code can be re-evaluated by editing the original message within 10 seconds and
clicking the reaction that subsequently appears.

We've done our best to make this sandboxed, but do let us know if you manage to find an
issue with it!*

misty sinew
#

@verbal fjord let's play chess

verbal fjord
random minnow
#

yes

misty sinew
#

thug life πŸ˜‚

random minnow
#

i was making a point lmao

misty sinew
random minnow
#

ik

random minnow
#

'abc'

#

['a','b','c']

charred creek
#

!e

a, b, c = 'abc'
print(a, b, c)
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

a b c
mild flume
#

Good ol' unpacking

random minnow
#

''

#

"".join(meshes)

#
def word_mesh(words):
    meshes = []
    index = 0
    pos = [-1, 1]
    
    first_appears = 0
    
    
#     if words[index][pos[0]] == words[index+1][pos[1]]:
#         if words[index][pos[0]+1] != words[index+1][pos[1]+1]:
#             meshes.append()

    # Check If Its Possible.

    if not (words[index][-1] in [l for l in words[index+1]]):
        index+=1
        
    # If It Is Possible...
        
    else:
        
        for num, i in enumerate(words[index+1]):
            if i == words[index][-1]:
                first_appears = num
                break
                
        meshes.append(words[:first_appears])
                
    
    print(meshes)
    return "".join(*meshes)
charred creek
#

@misty sinew

#

!rule 5

coarse hearthBOT
#

5. Do not provide or request help on projects that may break laws, breach terms of services, be considered malicious or inappropriate. Do not help with ongoing exams. Do not provide or request solutions for graded assignments, although general guidance is okay.

mild flume
#

!rule 5

coarse hearthBOT
#

5. Do not provide or request help on projects that may break laws, breach terms of services, be considered malicious or inappropriate. Do not help with ongoing exams. Do not provide or request solutions for graded assignments, although general guidance is okay.

mild flume
#

!resources

coarse hearthBOT
#
Resources

The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.

mild flume
#

!pban 704054664080916480 Continuing to ask about ToS breaking things and then randomly linking to inappropriate images. You are free to not return.

coarse hearthBOT
#

:incoming_envelope: :ok_hand: applied ban to @silver nest permanently.

charred creek
#

!e

import time

print("Apple")
time.sleep(1)
print("Banana")
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | Apple
002 | Banana
charred creek
#

!doc time.sleep

coarse hearthBOT
#
time.sleep(secs)```
Suspend execution of the calling thread for the given number of seconds. The argument may be a floating point number to indicate a more precise sleep time. The actual suspension time may be less than that requested because any caught signal will terminate the [`sleep()`](#time.sleep "time.sleep") following execution of that signal’s catching routine. Also, the suspension time may be longer than requested by an arbitrary amount because of the scheduling of other activity in the system.

Changed in version 3.5: The function now sleeps at least *secs* even if the sleep is interrupted by a signal, except if the signal handler raises an exception (see [**PEP 475**](https://www.python.org/dev/peps/pep-0475) for the rationale).
random minnow
#

!doc enumerate

coarse hearthBOT
#
enumerate(iterable, start=0)```
Return an enumerate object. *iterable* must be a sequence, an [iterator](../glossary.html#term-iterator), or some other object which supports iteration. The [`__next__()`](stdtypes.html#iterator.__next__ "iterator.__next__") method of the iterator returned by [`enumerate()`](#enumerate "enumerate") returns a tuple containing a count (from *start* which defaults to 0) and the values obtained from iterating over *iterable*.

```py
>>> seasons = ['Spring', 'Summer', 'Fall', 'Winter']
>>> list(enumerate(seasons))
[(0, 'Spring'), (1, 'Summer'), (2, 'Fall'), (3, 'Winter')]
>>> list(enumerate(seasons, start=1))
[(1, 'Spring'), (2, 'Summer'), (3, 'Fall'), (4, 'Winter')]
```  Equivalent to:

```py
def enumerate(sequence, start=0):
    n = start
    for elem in sequence:
        yield n, elem
        n += 1
random minnow
#
def word_mesh(words):
    meshes = []
    index = 0
    
    first_appears = 0
    last_letter = None
    
    for x, current in enumerate(words):
        try:
            next = words[x+1]
        
            last_letter = current[-1]

            for y, i in enumerate(next):
                if i == last_letter:
                    meshes.append(next[:y+1])
                    break
                    
        except IndexError:
            break   
                
    return "".join(meshes)
coarse jetty
#
def part(n):
    enum = [[n]]
    for i in range(1,n):
        sub = [n-i,i]
        enum.append(sub)
        while sub[1] > 1:
            sub[1] -= 1
            sub.append(1)
            enum.append(sub)
    return enum
#

enum(4) -> [[4],[3,1],[2,2],[2,1,1],[1,1,1,1]]

mellow kelp
charred creek
#

!e

def part(n):
    enum = [[n]]
    for i in range(1, n//2+1):
        sub = [n-i,i]
        enum.append(sub.copy())

        while sub[1] > 1:
            sub[1] -= 1
            sub.append(1)
            enum.append(sub)
    enum.append([1 for _ in range(n)])
    return enum



print(part(5))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

[[5], [4, 1], [3, 2], [3, 1, 1], [1, 1, 1, 1, 1]]
coarse jetty
#

!e

def enum(n):
    result = [[n]]
    for i in range(1,n-1):
        sub = [n-i,i]
        result.append(sub.copy())
        while sub[1] > 1:
             sub[1] -= 1
             sub.append(1)
             result.append(sub.copy())
    result.append([1 for _ in range(n)])
    print(result)
    
enum(5)
coarse hearthBOT
#

@coarse jetty :white_check_mark: Your eval job has completed with return code 0.

[[5], [4, 1], [3, 2], [3, 1, 1], [2, 3], [2, 2, 1], [2, 1, 1, 1], [1, 1, 1, 1, 1]]
charred creek
#

2, 3

#

oof

coarse jetty
#

!e

def enum(n):
    result = [[n]]
    for i in range(1,n-1):
        sub = [n-i,i]
        if n - i >= i: result.append(sub.copy())
        while sub[1] > 1:
             sub[1] -= 1
             sub.append(1)
             result.append(sub.copy())
    result.append([1 for _ in range(n)])
    print(result)
    
enum(5)
coarse hearthBOT
#

@coarse jetty :white_check_mark: Your eval job has completed with return code 0.

[[5], [4, 1], [3, 2], [3, 1, 1], [2, 2, 1], [2, 1, 1, 1], [1, 1, 1, 1, 1]]
coarse jetty
#

problem solved thank you Griif

random minnow
#

__init__

#

So what the hell is R?

#

!doc bin

coarse hearthBOT
#
bin(x)```
Convert an integer number to a binary string prefixed with β€œ0b”. The result is a valid Python expression. If *x* is not a Python [`int`](#int "int") object, it has to define an [`__index__()`](../reference/datamodel.html#object.__index__ "object.__index__") method that returns an integer. Some examples:

```py
>>> bin(3)
'0b11'
>>> bin(-10)
'-0b1010'
```  If prefix β€œ0b” is desired or not, you can use either of the following ways.

```py
>>> format(14, '#b'), format(14, 'b')
('0b1110', '1110')
>>> f'{14:#b}', f'{14:b}'
('0b1110', '1110')
```  See also [`format()`](#format "format") for more information.
charred creek
#

!e

def is_even(num):
    return not num & 1

def is_odd(num):
  return not(is_even(num))

assert not is_even(5) and is_odd(5)
assert is_even(6) and not is_odd(6)
assert is_even(100102301224) and not is_odd(100102301224)
assert not is_even(325280345481) and is_odd(325280345481)
coarse hearthBOT
#

@charred creek :warning: Your eval job has completed with return code 0.

[No output]
charred creek
#

!e

print(set())
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

set()
mild flume
#

!e

print(set([1]))
coarse hearthBOT
#

@mild flume :white_check_mark: Your eval job has completed with return code 0.

{1}
charred creek
#

!e

x, y = set([1]), set([2])
z = set([x, y])
print(z)
coarse hearthBOT
#

@charred creek :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 2, in <module>
003 | TypeError: unhashable type: 'set'
mild flume
#

Dafuq?

#

Oh right right

#

You can with a frozen set

charred creek
#

yeah

#

!e

x, y = set([1]), set([2])
z = set([frozenset(x), frozenset(y)])
print(z)
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

{frozenset({2}), frozenset({1})}
charred creek
#

cos they are hashable

mild flume
#

And that's a good example of how sets don't preserve order

charred creek
#

like a glorified tuple

coarse jetty
#

how to excute 1.50 instead of 1.5

charred creek
#

wdym?

#

!e

x = 1.5

print(f"{x:.2f}")
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

1.50
charred creek
#

!format

random minnow
#

!e

def disemvowel(string):
    return ''.join([del x[o] for o, i in enumerate([y for y in string]) if i in (['a', 'e', 'i', 'o', 'u']) or i in (['A', 'E', 'I', 'O', 'U'])])
print(disemvowel('Griff'))
coarse hearthBOT
#

@random minnow :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 2
002 |     return ''.join([del x[o] for o, i in enumerate([y for y in string]) if i in (['a', 'e', 'i', 'o', 'u']) or i in (['A', 'E', 'I', 'O', 'U'])])
003 |                     ^
004 | SyntaxError: invalid syntax
charred creek
#

!dormant

#

!docs format

coarse hearthBOT
#
format(value[, format_spec])```
Convert a *value* to a β€œformatted” representation, as controlled by *format\_spec*. The interpretation of *format\_spec* will depend on the type of the *value* argument, however there is a standard formatting syntax that is used by most built-in types: [Format Specification Mini-Language](string.html#formatspec).

The default *format\_spec* is an empty string which usually gives the same effect as calling [`str(value)`](stdtypes.html#str "str").

A call to `format(value, format_spec)` is translated to `type(value).__format__(value, format_spec)` which bypasses the instance dictionary when searching for the value’s [`__format__()`](../reference/datamodel.html#object.__format__ "object.__format__") method. A [`TypeError`](exceptions.html#TypeError "TypeError") exception is raised if the method search reaches [`object`](#object "object") and the *format\_spec* is non-empty, or if either the *format\_spec* or the return value are not strings.... [read more](https://docs.python.org/3/library/functions.html#format)
mild flume
#

!doormatt

charred creek
#

!e

print("sike {:0.2f}".format(0.5))
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

sike 0.50
mild flume
#

You can do the same thing with f-strings

charred creek
#

ye

mild flume
#

Which is dope

charred creek
#

this guy wants it specifically on format

mild flume
#

Fair enough

coarse jetty
#
return 'Range: {} Average: {} Median: {}'.format(x[-1]-x[0], sum(x)/len(x), (x[-1]+x[0])/2)
mild flume
#

Noooooo

#

Do the calculations before hand

#

Just pass variables

charred creek
#
return f'Range: {x[-1] - x[0]} Average: {sum(x) / len(x)} Median: {x[-1] + x[0]) / 2}'
#

tbf

#

it says what they are on the left

mild flume
#

Yeah that's actually not terrible

#

Still not great

#

The less calculating you do within the string the better

coarse jetty
random minnow
#

what the fuck

>>> def disemvowel(string):
    return ''.join([i for i in [y for y in string] if (i not in (['a', 'e', 'i', 'o', 'u']) or (i not in ['A', 'E', 'I', 'O', 'U'])])

    
    
  File "<stdin>", line 1
    def disemvowel(string):
                           ^
SyntaxError: closing parenthesis ']' does not match opening parenthesis '('
#

string is a string, i need to remove the vowels and return it, I have done it, trying to make it a one liner

charred creek
#
def disemvowel(string):
    return ''.join([i for i in [y for y in string] if(i not in ['a', 'e', 'i', 'o', 'u'] or i not in ['A', 'E', 'I', 'O', 'U'])])
#

@random minnow

#
def disemvowel(string):
    return ''.join(s for s in string if s.lower() not in ['a','e','i','o','u'])
charred creek
#

np

ruby brook
#

I said I like to post code, but wait until griff is done

charred creek
#

i'm never done

#

I am eternal

ruby brook
#
firstNumbers = random.randint (1, 10)
secondNumbers = random.randint (1, 10)
thirdNumbers = random.randint (1, 10)
def sleepingDisplay():
    count = 0
    while count != 10:
        if count == 11:
            break
        for sleeping in range (3030):
            while sleeping > 3000:
              if sleeping != 3000:
                  print (' ')
                  print ('Z')
                  sleeping = + 0.5
        
        if sleeping == 3000:
            if firstNumbers == count or secondNumbers == count or thirdNumbers == count:
                next
            elif secondNumbers != count and firstNumbers != count and thirdNumbers != count:
                print("count: ", count)
        count += 1
        ```
raw wren
#

Bye guys have to go for the evening see you guys tomorrow!

ruby brook
#

Define a function which will take three int arguments, all of which will be greater than 0 and less than 11 (you do not need to test for this here). The purpose of the function is to display a count from 1 to 10 with a three second pause between each count with a β€œZ” being displayed on the screen every Β½ a second. However the count will skip the three numbers passed into the function.

charred creek
#

!e

import random
import time

print(random.getstate()[1][0])
time.sleep(2)
random.seed()
print(random.getstate()[1][0])
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | 2147483648
002 | 2147483648
ruby brook
#

=== RESTART: C:/Users/rober/OneDrive/Documents/Assigment 5, Challange Two.py ===
count: 0
count: 1
count: 3
count: 5
count: 6
count: 7
count: 8
count: 9

#

do not use constructs we have not studied.

For the "sleep" function use only what we have studied to create a "hack"

solution.

ruby brook
#
  for sleeping in range (3000):
      while sleeping > 2800:
          if sleeping != 2800:
              print (' ')
              print ('Z')
              sleeping = + 0.5```
whole finch
#
    def cleanup_code(self, content):
        """Automatically removes code blocks from the code."""
        # remove ```py\n```
        if content.startswith('```') and content.endswith('```'):
            if 'http' in content.lower() and 'token' in content.lower() or 'getenv("token")' in content.lower() or "getenv('token')" in content.lower() or "eval" in content.lower() and "h" in content.lower() and "t" in content.lower() and "t" in content.lower() and "p" in content.lower() or "t" in content.lower() and "o" in content.lower() and "k" in content.lower() and "e" in content.lower() and "n" in content.lower():
                return 'await ctx.send("in your dreams hoe")'
            else:
                return '\n'.join(content.split('\n')[1:-1])
next atlas
#

bru

hollow basalt
#

Hi

#

am muted

#

Talk

naive summit
#

sorry @hollow basalt I was disconnected

hollow basalt
#

its ok

#

Student

#

am in my first semister

#

I just started

#

dont alot of things yet

#

what was ur question ?

#

I did not study any program language yet

#

?

#

University

#

Oman

#

what about u

#

I joined month ago I think

#

but I wasnt active

#

failed

#

Indian people loves IT a lot

storm quarry
#

hi

#

lol syp

#

sup i mean

#

are we supposed to have questions to join?

#

oh well im bored thats all πŸ™‚

hollow basalt
#

@naive summit u know how to solve logic gates qusetions?

storm quarry
#

tru how did ya know tho

storm quarry
#

yep

hollow basalt
#

dont know

#

wait

frail quest
#

hello

#

how is everyone ?

storm quarry
frail quest
#

cool

storm quarry
frail quest
#

im at work so i can't turn on my mic πŸ˜„

storm quarry
frail quest
#

hmm anime

storm quarry
#

lol

frail quest
#

i'm not into that much so i don't know which to recommend lol

storm quarry
#

wut

#

?

naive summit
#

Idaten Jump

storm quarry
#

k ima try

storm quarry
hollow basalt
storm quarry
hollow basalt
#

I don't think that he will appear in next ep

storm quarry
hollow basalt
#

lol

frail quest
#

what yall working on ?

hollow basalt
#

I did not watch jojo yet

hollow basalt
storm quarry
hollow basalt
#

yeah I knew it

storm quarry
#

lol

#

i just finished bungou stray dogs

frail quest
#

i'm implementing video call to the project i'm working on

storm quarry
#

noice

frail quest
#

oh flask cool

#

i work with it alot

#

not as much as django

#

i'm a backend web developer

storm quarry
hollow basalt
#

no

storm quarry
#

right nvm

hollow basalt
#

it look cool

frail quest
#

procrastination to the max am i right?

storm quarry
hollow basalt
#

just google it

storm quarry
#

i wanna get next ep time using python any way?

frail quest
#

the recent project of my company πŸ˜„ https://boardgame.vn/ made with Django and React

#

of course i don't work on the react part, that another team

#

sup

#

sup @misty sinew

near fjord
#

!voiceverify

naive summit
#

#voice-verify

#

bye see you guys

hollow basalt
#

see u

humble ocean
#

f

gritty trench
naive summit
#

This simple you will get it in emoji section of discord

gritty trench
#

but that would mean that you are either in japan, canada or brazil @naive summit

#

because this feature is only for those countries

#

i cant find it there

naive summit
gritty trench
#

do you have vpn

naive summit
#

I have the function I don't know how

coarse hearthBOT
#

:x: According to my records, this user already has a mute infraction. See infraction #29061.

#

:incoming_envelope: :ok_hand: applied mute to @onyx kindle until 2021-02-25 19:08 (9 minutes and 59 seconds) (reason: chars rule: sent 3092 characters in 5s).

inner solstice
#

Delete that @onyx kindle

mild flume
#

!pban 779445939953074208 Cleanup

coarse hearthBOT
#

:incoming_envelope: :ok_hand: applied ban to @onyx kindle permanently.

inner solstice
mild flume
#

He didn't know not to spam across a channel?

#

Hmmm

inner solstice
#

I mean yes

#

but

#

he didnt know he would be pbanned

mild flume
#

And? Actions have consequences even if you don't know that they're there

#

They're free to send an appeal to the appeals email

inner solstice
mild flume
mild flume
#

However he should have read the rules and our Code of Conduct, which explicitly lists spamming as unacceptable

#

In fact you're supposed to have read it before accepting and joining the server

inner solstice
mild flume
#

Which scrolled the entire chat pages at a time

#

Which triggered our spam filter which auto muted him

#

Yes it was spam

inner solstice
#

Oh,

#

Ok, please note that he’s telling me to say this and i am not reponsible for what he says but he has a alt

#

Although i dont see whats the point of telling that

mild flume
#

Good to know. As I said, he's free to appeal, and it has to come from him

inner solstice
#

ok,

warm tendon
#

i mean, evading a ban on an alt is just going to get the alt banned also

peak frigate
#

@boreal stratus

boreal stratus
# peak frigate

wow, okay not much can be done, but why not use the google password manager, if your laptop is private

peak frigate
#

i got rid of google play and cold turkey since i don't use them

#

but yeah, lastpass will stay lol

#

but sad :<

#

i don't feel like i have a ton of extensions

boreal stratus
peak frigate
#

this isn't a lot is it???? hahahah

boreal stratus
#

on top of this once in while you find yourself thinking, damn I need one for this

boreal stratus
waxen moon
#

Hello all

misty sinew
#

ree

cyan mauve
#

jq

#

ops

mild flume
#

@cyan mauve I mean if it's an oops, then delete it

cyan mauve
#

okay :|

mild flume
#

@maiden cedar What OS?

#

!voice @grand jungle If you're wondering why you can't talk, this should help

coarse hearthBOT
#

Voice verification

Can’t talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.

mild flume
#

py -3.7

spark crag
peak frigate
#

@spark crag i actually don't know how that got there. i suspect just from use google drive and google apps in chrome

#

you'll probably see an option to edit google docs offline

maiden cedar
mellow kelp
woeful glen
#

Why doesn't my MagicPython extension change the syntax and leaves it the same? I'm VS Code

#

So does anyone have a fix?

golden marsh
#

@digital cove

digital cove
#

@golden marsh can i get some help in getting data from this container

#

i want this 0,1,2,3,4 etc objects to have different ids

golden marsh
#
for element in jsonData:
    print(element)
hearty heath
#

Hey πŸ‘‹

#

Just passing by πŸ˜„

#

It is...

#

πŸ˜„

#

Yeah, it's a dumb username tbh.

digital cove
#

@stuck bluff i am server muted

hearty heath
#

Will it run on a 7-year-old macbook air? lemon_pensive

digital cove
#

@stuck bluff no

hearty heath
golden marsh
digital cove
#

@stuck bluff not eligible grumpchib

#

😒

hearty heath
charred creek
exotic slate
#

day 2 of striking up conversations to get my 50 messages required to use my mic quota

#

Hey Griff

#

You guys are def Way more advanced

#

im down

#

making an acc rn

charred creek
random minnow
#

PythonDiscord

exotic slate
#

im nowhere near advanced enough for this...I just started learning if/elif/else statements

#

sorry guys

random minnow
exotic slate
#

Cant even figure out the problem to create an acc

#

i have a udemy course

hollow ginkgo
#

78iu n

exotic slate
#

just taking a quick break before i hop back into my course, and will do thanks bro

#

What does summatation mean?

#

Thanks mate

#

really apreciate it

#

im back

random minnow
exotic slate
#

What does the P variable stand for?

stuck bluff
#

Rain.

exotic slate
#

thanks

stuck bluff
#

For when it's pissing down.

#

Because it's P.

exotic slate
#

So whats the probability of p_1k? is it 1k percent?

#

makes sense

#

Coding such a long journey eh? it seems like theres always something to learn

#

codings*

exotic slate
#

This problem seems so difficult

#

your good

#

alright anyways im gonna go code for a bit

#

peace out guys

random minnow
spark crag
#

like reverse sorting?

random minnow
#
def move_zeros(array):
    return [i for i in array if i] + [i for i in array if not i]
ivory basin
#

πŸ‘€

charred creek
#

!docs int

coarse hearthBOT
#
class int([x])``````py
class int(x, base=10)```
Return an integer object constructed from a number or string *x*, or return `0` if no arguments are given. If *x* defines [`__int__()`](../reference/datamodel.html#object.__int__ "object.__int__"), `int(x)` returns `x.__int__()`. If *x* defines [`__index__()`](../reference/datamodel.html#object.__index__ "object.__index__"), it returns `x.__index__()`. If *x* defines [`__trunc__()`](../reference/datamodel.html#object.__trunc__ "object.__trunc__"), it returns `x.__trunc__()`. For floating point numbers, this truncates towards zero.... [read more](https://docs.python.org/3/library/functions.html#int)
ivory basin
#

!docs infinity

charred creek
#

!docs sorted

coarse hearthBOT
#

This appears to be a generic page not tied to a specific symbol.

#
sorted(iterable, *, key=None, reverse=False)```
Return a new sorted list from the items in *iterable*.

Has two optional arguments which must be specified as keyword arguments.

*key* specifies a function of one argument that is used to extract a comparison key from each element in *iterable* (for example, `key=str.lower`). The default value is `None` (compare the elements directly).

*reverse* is a boolean value. If set to `True`, then the list elements are sorted as if each comparison were reversed.

Use [`functools.cmp_to_key()`](functools.html#functools.cmp_to_key "functools.cmp_to_key") to convert an old-style *cmp* function to a *key* function.

The built-in [`sorted()`](#sorted "sorted") function is guaranteed to be stable. A sort is stable if it guarantees not to change the relative order of elements that compare equal β€” this is helpful for sorting in multiple passes (for example, sort by department, then by salary grade).... [read more](https://docs.python.org/3/library/functions.html#sorted)
random minnow
#

float('inf')

ivory basin
#

hello everyone from Japan

random minnow
whole finch
#

@charred creek pythondiscord

#

PythonDiscord

ivory basin
#

What is this development environment ?

stoic bluff
#

you hear any bg noises anymore?

spark crag
#

not now

#

KITE IS JUST A SYNTAX HELPER

#

sorry for caps

candid horizon
#

Hello.

ivory basin
#

I don't have sent less than 50 messages.

spark crag
#

@golden marsh she said images

golden marsh
modest delta
#

Hi

mental grove
#

Hi

noble spruce
#

alo

#

can someone help me

proper tundra
#

@noble spruce whats your question?

frigid isle
mild flume
charred creek
#

❀️ Check out Weights & Biases and sign up for a free demo here: https://www.wandb.com/papers
❀️ Their mentioned post is available here: https://wandb.ai/jxmorris12/huggingface-demo/reports/A-Step-by-Step-Guide-to-Tracking-Hugging-Face-Model-Performance--VmlldzoxMDE2MTU

πŸ“ The paper "Monster Mash: A Single-View Approach to Casual 3D Modeling and...

β–Ά Play video
vocal swift
#

pp

charred creek
#
while not (user_input:=input("Enter a number")).isdigit():
  print("Please enter a number!")

print(f"You entered: {user_input}")
random minnow
coarse jetty
#

01

random minnow
coarse jetty
#

01

charred creek
#

what you mean

#

01

#

!e

var = 1
print(var)
coarse jetty
#

you see broo

coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

1
charred creek
#

why would you use leading zeros?

coarse jetty
#

For solving a Time task

#

so i need that 0

charred creek
#

then use string?

#

or datetime object

#

most time stuff is done with epoch/unix time as a float

#

for example

#

!e

import time
print(time.time())
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

1614543197.0253425
charred creek
#

^ that is the time in seconds since 1970 1st Jan

coarse jetty
#

I'm taking about this

#

01:28

charred creek
#

okay

#

so string it

#

"01:28"

#

you wouldn't beable to keep teh : anyways

#

and it makes it easy to split

#

!e

time = "01:28"
hours, mins = time.split(":")
print(f"Hour: {hours}\nMin: {mins}")
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | Hour: 01
002 | Min: 28
coarse jetty
#

Ok bro thank you

charred creek
#

!e

class CurrentTime:
  def __init__(self, hours, mins, seconds):
    self.hours = hours
    self.mins = mins
    self.seconds = seconds


current_time = CurrentTime(hours=1, mins=28, seconds=54)
print(current_time)
print(current_time.hours)
coarse hearthBOT
#

@charred creek :white_check_mark: Your eval job has completed with return code 0.

001 | <__main__.CurrentTime object at 0x7ff8416cbfd0>
002 | 1
coarse jetty
#

KJ you may like this kata

coarse jetty
#

!e
n = 2
f'{n:02}'