#voice-chat-text-0
1 messages Β· Page 31 of 1
You work in accounting?
What do you even do in accounting you just make bank accounts for people?
Taxes, business services like payroll, auditing, stuff like that
Oh shiiit thats such a good job π€―
Ehhhhhhhhhhh
auditing is good π
It's tedious, and it makes me happy I'm not an accountant. I'm happier being in house IT
Damn
And when tax season is happening, there's a lot of frustration, anger, depression, etc. High stress for a few months out of the year, mild irritation the rest
I'm just here to keep them happy and working
I'm not a programmer by trade
To combat Russiaβs immense military power, Ukraine has built an army of drones, turning everyday aerial vehicles into military weapons that have helped change the momentum of this war.
#Drones #Ukraine #Military
Watch The National live on YouTube Sunday-Friday at 9 p.m. ET
Subscribe to The National:
https://www.youtube.com/user/CBCTheNation...
The MiniHawk-VTOL is a 3D-Printed VTOL aircraft. The design is intended to provide the robotics and FPV community with a common and accessible VTOL testbed for experimentation, either as a platform for flying robotics behaviors and tasking, and/or for FPV. The aircraft is designed to integrate a set of (optional) flexible solar cells for migrato...
Wait does the % operator mean divide or remainder I can't determine?
yea basically remainder
Is the remainder the thing they taught us in grade 2 in long division?
Wtf
Ok
But is the remainder the thing they taught us in grade 2 when doing long division?
Ok
But Idk any of that d*y+r = x stuff
So when would you use this dy+r=x?
Ok I have zero clue what that stuff means but I get the remainder stuff
hi @woeful salmon
What's d?
hello π
Is there a word for it?
Oh yea remainder is 3 because 5*2 = 10 and the extra 3 is remainder
What kind??
Simulation based
Yea not experienced for that stuff ask AF he might know or ask Mr. Hemlock he also might know
Wait what's the <=?
and >=?
Oh
β€ just use that
β€β₯ ez
you on mac?
or windows?
Is there an option key at the bottom left of your keyboard.
Damn
Theyβre useful tho
Ha noob
discord cuts the \ π¦
Why does 8/2 go first when there's multiplication behind it? is it because of the brackets??
hello :)@rugged root
@rugged root Sorry for the ping but ya able to help out?
results = modifications(event_type, event_time, row_id)
noodle got any browser games
not really
π₯Ή
been much into path of exile these days which is not browser either ><
til what unsigned int is ty Maroloccio
I can't at the moment
i need to go now see you guys later
I have to focus on something for work
Nooooo
@woeful salmon Why have you forsaken me!?!?
Miss ya, bud
Heck work
well not feeling great right now
Hang out with us
feel better soon
i forgot i don't handle burgerking burgers well for some reason T-T
idk why everytime i eat one i feel sick
Alr
forgive me for this π
@dusk raven
@rugged root ig this is what u meant
I wonder what this could be
play
magic
please#
i see
this one is good as well
Yep, that
want the source code to make that?
https://www.amazon.com/gp/product/B0B4SWQ39Y/ Oh regarding the black friday thing, I'm getting one of these to expand my PS5.
Officially licensed for PlayStation 5 consoles, the WD_BLACK SN850 SSD for PS5 consoles allows you to store and play PS5 games and PS4 games. The heatsink design makes installation worry-free in your PS5 M.2 expansion slot. Instantly expand up to 1TB of additional storage to hold up to 50 games (...
Not at the moment, no
Appreciated, though
aight
@tough wind Hello
Ah, gotcha
creating a programming language
just started
creating for my os
ok
lag
What distro for school?
@midnight agate are u back later?
isnt it whale poo? @rugged root
i guess thats not a liquid
what was the message in morse? @gentle flint
typegang
This is the official commercial for Milwaukee's Monster Truck Holocaust '13. Please note that due to a restraining order, Erin Moran is no longer able to take part in the autograph session. Peeps McDrummond, the world's greatest Gary Coleman impersonator, will instead take Miss Moran's place.
This is the database backend for it
It is tedious
py -3.9
py -0
EVERY DRUG?? now we know why his throat is fucked!
py -3.9 -m venv .
Fantaisie Impromptu, Chopin Op. 66
Click the πbell to always be notified on new uploads!
β« Listen on Spotify: http://spoti.fi/2LdpqK7
β« Sheet Music on nkoda: http://bit.ly/nkodaChopinFantaisieImpromptu
β« MIDI: https://patreon.com/rousseau
β« Facebook: http://bit.ly/rousseaufb
β« Instagram: http://bit.ly/rousseauig
β« Twitter: http://bit.ly/rousseau...
.xkcd 37
@rugged root we meet again
β« -- @rugged root 's π§
Been okay. Although I'm sorry to say I'm not recognizing you...
When we talked was it under a different account possibly?
I dont remember its been a long time
Well I apologize for not remembering you
streams/examples/src/main/java/org/apache/kafka/streams/examples/wordcount/WordCountDemo.java lines 75 to 85
static void createWordCountStream(final StreamsBuilder builder) {
final KStream<String, String> source = builder.stream(INPUT_TOPIC);
final KTable<String, Long> counts = source
.flatMapValues(value -> Arrays.asList(value.toLowerCase(Locale.getDefault()).split("\\W+")))
.groupBy((key, value) -> value)
.count();
// need to override value serde to Long type
counts.toStream().to(OUTPUT_TOPIC, Produced.with(Serdes.String(), Serdes.Long()));
}```
Cannot infer type argument(s) for <VR> flatMapValues(ValueMapper<? super V,? extends Iterable<? extends VR>>)
@rugged root
oh you would mr. hemlock
Perhaps a hint then
Perhaps one of the folks who had given me death threats or doxxing? Hard to keep track
No thats not me
Then the one that's been trying to get help parsing html in that weird way?
@hot harbor π
hi
Hai LP π
!voice
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
Sorry, I'm not as keyboard agile as I might otherwise would be.
I've got a frankensetup.
vnc and audio streaming
Yeap
The time will come when humanity will go "oh, shit, we shouldn't have wasted all that helium"
my god
im sorry bro i cant talk to you
But you are.
That would require my brain being in the zone.
I am thoroughly unzoned.
It is a good word and bears repeating. Alas.
I'm responding to voice conversation.
If you were logical, you should not be a sunflower now
ahah sorry
Speak plainly.
I mean, if you were a rational person, you shouldn't be like your sunflower profile
Your meaning is unclear.
Please explain it to me clearly.
@zenith radish Yeah, I didn't expect it to be too busy.
This is a famous Iranian joke
I thought you were talking to yourself before you told me that I was talking to someone else
Please tell me this Iranian joke.
Will telling a joke kill you? Well, I suppose if you're Iranian, it might.
Depends on the joke.
From my point of view, you were talking to yourself, you were chatting and giving your own answers
But that person is talking on voice... and here everyone is watching your chat
This is an Iranian proverb.... If there are two cooks... food is either salty... or unsalted.... I mean, why is one in Voice and one in Chat
It sounds like a proverb about the quantum uncertainty principle.
We'll often talk in voice, but also utilise chat.
Brother, don't worry, this is a proverb and it was written mostly for old stories
kvanker where are you from?
iran
aha
nice
nesf jahan
marg bar dictator
I was like this for a while when I didn't have a microphone...someone would speak in the middle of the game, I had to write the answer in the chat, and when I returned, I would be killed in the game.
There is no dictatorship, traitor
I'm in a similar predicament at the moment.
i know
... oh ur a basiji
this is hard
na
man as basij badam miad
vali tarafdar keshvaram hastam
va khaham mand
to tarafdar geruni hasti?
English, please.
bro hes anti revolution
I'm not a complete idiot.
I am a supporter of our president and leader
Expensiveness belongs to stupid officials
They come to kill people
Prove what you say
our system is corrupt to the core, they all have to go
You should also go because you do not belong to your country and you are against it
<@&831776746206265384> I'm dreadfully sorry, but I think we need a babysitter.
maybe khomeini was not a bad person and not a theif but khomenei and his unerlings are theives
they murdered a 10 year old a few days ago...
basiji
barat motasefam
Brother, don't mess up your server, make it one, your entire server will now become a political discussion
thats not good
sus
the revolution is trying to kick out those exact government officials you agree are stupid
I am not your brother. π
Hi LX, HI Opal, HI ALL
hai
you have access to the internet unline many people, read a book, open your eyes, they are theives and murderers and must go
@lethal thunder @hot harbor Guys, I don't think this is really an appropriate conversation for this server. Would you mind moving to DMs if you want to continue?
Yo π
im done, i just pity someone who has access to the internet and still decides to blindly follow a murderous regime.
I don't like to discuss politics, I want to close Discord and go to work...you should let him know that
ok?
I come here whenever I have problems or problems with Python
bye
Maro, X or Y?
Maro, might want to mute?
Ohhh π
His name is now Harold
They're noisy and kind of weird looking, but it's still cute
I hope Harold has a nice day
It actually told off the bossy crested pigeon, too, which was amazing.
π
Saw a bluetongue skink the other week. The echidna hasn't been spotted beyond the two recent sightings.
Nothing.
Tell a dad joke with several witty puns!
You can do it! Believe in yourself!
The nearest level is probably in the shed
Spirit level
Is it costs that much for a plane ticket, how much more expensive are the decorated ones?
hai
wget - The w doesn't stand for water.
it does for me
Er, wat?
er, that
So I take it you're back homeish, now?
Best thing, worst thing, weirdest thing. Go.
@elfin urchin π
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
:incoming_envelope: :ok_hand: applied mute to @whole bear until <t:1669329398:f> (10 minutes) (reason: duplicates rule: sent 4 duplicated messages in 10s).
The <@&831776746206265384> have been alerted for review.
Howdy howdy.
I heard a little whisper, then, at volume, "Audio check: fail."
I can hear you, but you're on the quiet side.
hai AF
You might be okay.
Keep it as is.
I'd say it's good.
@hybrid jolt π
I would speak, but I'm not in a position to at the moment.
Worship worship, grovel grovel.
I don't follow.
I've not alleged any such thing.
You may get an honest answer, but you might not get an answer that satisfies.
Do I understand? In general, yes. Insomuch as anyone can really understand anyone else.
I don't always follow everything.
Occasionally, I think "so. many. words."
Brevity may not be a virtue, but it ought to be.
I waffle, too.
I get it.
People do like to hear what you have to say.
But there is only so much listening the ear can do.
I dislike the characterisation of "fixing your personality flaws"
We can become aware of ourselves. How we feel about ourselves, how others feel about us.
That awareness allows adjustment.
Development.
Hi Af, Hi Maro, Hi Opal
hi
Yeah, you caught him as he was going.
He'd been about to go for a few minutes.
For my love is deep and encompassing.
Yeah, I'm just not in a position to talk for the time being.
Oh, I thought...nevermind.
Wait
really confused
you are voice verified but are muted on purpose
is that what you mean?
I got you
I do the same
most of the time
I like to listen because there are a lot of good learning opportunities
Small bites.
Really eating that elephant...
Chewable.
Hm?
sorry
hard to find a good link
I sometimes wonder just how close we are to a Girl With All the Gifts scenario.
Leucochloridium paradoxum, the green-banded broodsac, is a parasitic flatworm (or helminth). Its intermediate hosts are land snails, usually of the genus Succinea. The pulsating, green broodsacs fill the eye stalks of the snail, thereby attracting predation by birds, the primary host. These broodsacs visually imitate caterpillars, a prey of bird...
the chance increases every day that goes by :>
if it were a possibility of happening
then you have a timeline
each day that passes
π
really depends on how you look at it
rng
we take over galaxys and use them to run simulations
I completely understand what you are saying
I really don't want to do this ;-;
I am too tired to go down a rabbit hole
good fun though
love the attitude
@solid trail Per Rule 6, your invite link has been removed. If you believe this was a mistake, please let staff know!
Our server rules can be found here: https://pythondiscord.com/pages/rules
@golden sparrow π
π
@upbeat vale π
hello
@golden hazel π
!voice
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
i see thanks
is there any chance you can explain to me how a "for loop" goes throught a matrix im bout to send you? Its a quick question if you let me explain what the loop is for
Basically, i want to see if there is a recursion in the matrix. Ive made a function that works but i dont know how the "i" moves through the matrix
!code
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.
i see i see
yeye
i understand...thanks
one more question if i may
sometimes when I want to make a for loop to go through an array or a list lets say....i type in....for i in range(len(array)). But quite often i get an error saying "out of range" (i think) and I fix it by putting (len(array)-1). I dont understand when do i have to put the "-1" and when not to
!e py "abc"[3] #index 3 meaning "the fourth thing"
@somber heath :x: Your 3.11 eval job has completed with return code 1.
001 | Traceback (most recent call last):
002 | File "<string>", line 1, in <module>
003 | IndexError: string index out of range
oh
!e py for letter in "abc": print(letter)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | a
002 | b
003 | c
!e py text = "abc" for i in range(len(text)): print(text[i])
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | a
002 | b
003 | c
!e py text = "abc" for i, letter in enumerate(text): print(f"{letter} is at index {i}")
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | a is at index 0
002 | b is at index 1
003 | c is at index 2
hello again
@surreal wyvern A Common Sense Guide to Data Structures and Algorithm
`py
print("hello world")
'''print("hello world")'''
print("hello world")
py print("hello world")
print("hello world")```
Hi
thank you
I have like 120 discord servers, it's hard to keep track
that is true
well, I created this account back in 2016
text chat is not that bad
after all
my typing speed is 120 WPM,
ups
so I won't have a problem typing
80 is enough
use type racer
it helps you get above 100
nope, it's not important at all
what matters is that you do the SOLID principles with good OOP practices with team
BUT
it looks cool
yup
plus
sometimes I just don't want to code at all
and I want to play games
so I play typeracer
play MMORPG games as a developer
because we don't have real life >.> \
:incoming_envelope: :ok_hand: applied mute to @hidden jacinth until <t:1669479422:f> (10 minutes) (reason: duplicates rule: sent 4 duplicated messages in 10s).
The <@&831776746206265384> have been alerted for review.
hello
@vague igloo π
hey ! i don t have th permission to open th mic why is that π
!voice
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
!code
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.
import numpy as np
import time
import heapq
from math import sqrt
from sklearn.model_selection import train_test_split
import pandas
start=time.time()
iris=pandas.read_csv("iris.csv")
z=iris.loc[:,"petal_length"]
y=iris.loc[:,"petal_width"]
lab=iris.loc[:,"species"]
def distance_euclidean (a, b):
euclidean_distance = pow(a[0]-b[0],2)+pow(a[1]-b[1],2)
return (sqrt(euclidean_distance))
# make kd tree
def kdTree(point, dim, i=0):
if len(point) > 1:
point.sort(key=lambda x: x[i])
i = (i + 1) % dim
half = len(point) >> 1
return [
kdTree(point[: half], dim, i),
kdTree(point[half + 1:], dim, i),
point[half]
]
elif len(point) == 1:
return [None, None, point[0]]
# k nearest neighbors
def find_knn(node, point, k, dim, dist_euc, return_distances=True, i=0, heap=None):
is_root = not heap
if is_root:
heap = []
if node is not None:
distance = dist_euc(point, node[2])
dx = node[2][i] - point[i]
if len(heap) < k:
heapq.heappush(heap, (-distance, node[2]))
elif distance < -heap[0][0]:
heapq.heappushpop(heap, (-distance, node[2]))
i = (i + 1) % dim
# Goes into the left branch, and then the right branch
for b in [dx < 0] + [dx >= 0] * (dx * dx < -heap[0][0]):
find_knn(node[b], point, k, dim, dist_euc, return_distances, i, heap)
if is_root:
neighbors = sorted((-h[0], h[1]) for h in heap)
return neighbors if return_distances else [n[1] for n in neighbors]
d=list(zip(z,y))
x=(5,1) # point of study
k = 5 # number of neighbours
#split dataset into train and test data
xy_train, xy_test, lab_train, lab_test = train_test_split(d, lab, test_size=0.2, random_state=0,
stratify=lab)
#xy_train from tuple to list - 2 dimensions
liste_xy_train = [ [ xy_train[i][0] , xy_train[i][1] ] for i in range(len(xy_train)) ]
#split species for test and train
species_test = [f for f in lab_test]
species_train = [f for f in lab_train]
correct = 0
#Take all the class labels of all the nearest k neighbors.
for j in range (len(xy_test)):
t = kdTree(liste_xy_train, 2 ,0)
g = find_knn(t, xy_test[j] , k, 2, distance_euclidean, True, i=0, heap=None)
nearest_neighbors=[g[i][1] for i in range(len(g))]
nearest_neighbors_new = [tuple(l) for l in nearest_neighbors]
list_species_knn=[]
#index of tuples in the training data
for i in range(len(nearest_neighbors_new)):
indice=xy_train.index(nearest_neighbors_new[i])
count0 = list_species_knn.count(0)
count1= list_species_knn.count(1)
count2 = list_species_knn.count(2)
#Find the majority class label.
if max(count0,count1,count2)==count0 :
prediction=0
if max(count0,count1,count2)==count1:
prediction=1
if max(count0,count1,count2)==count2:
prediction=2
print(f"Expected {species_test[j]} Get {prediction}")
#Calculate the prediction accuracy
if prediction==species_test[j]:
correct = correct+1
print(f"correct = {correct}")
print(f"Accuracy = {correct/len(xy_test)*100} ")
end=time.time()
print('Time consumed: {} secs'.format(end-start))
Nobody saw anything here
do it again
No I am verified now!!
what are you guys talking about
idk
i'll probably just listen but i'm just a newbie to programming if that is the topic
whatup @somber heath
hi
!e ```py
def func():
return 5
v = func() #func() here being the call to func.
print(v)```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
5
#this is like writing
v = 5```
code
!e py v = print("Hello, world.") print(v)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | Hello, world.
002 | None
!e ```py
def func():
"Code here..."
print(func())```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
None
x = 12
!e py a = [] b = [] c = a print(a == b) #True. The object refered to by a is equal to the object referred to by b. They are both empty lists. print(a is b) #False. The object referred to by a is not the same object refered to by b. print(a is c) #True. a refers to the one, same object that c refers to.
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | True
002 | False
003 | True
a = 1
b = 1
c = a
print(a == b)
print(a is b)
print(a is c)
!e py d = {"apple": 5, "pear": 8, "banana": 10} print(d.keys()) print(d.values()) print(d.items())
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | dict_keys(['apple', 'pear', 'banana'])
002 | dict_values([5, 8, 10])
003 | dict_items([('apple', 5), ('pear', 8), ('banana', 10)])
i cant talk
its really easy
I am trying to do cs50 but i connected vs code
to their workspace
how i use vscode normal
my vscode is connected
ok ty anyway
!e py d = {} d["apple"] = 5 d["pear"] = 8 print(d) print(d["apple"])
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | {'apple': 5, 'pear': 8}
002 | 5
!e py a, b = [1, 2] print(a) print(b)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | 1
002 | 2
!e py d = {"apple": 5, "pear": 8, "banana": 10} for key, value in d.items(): print(f"The key is {key} and the value is {value}.")
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | The key is apple and the value is 5.
002 | The key is pear and the value is 8.
003 | The key is banana and the value is 10.
!code
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.
!e py d = {"apple": 5, "pear": 8, "banana": 10} for keyvalue in d.items(): print(keyvalue)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | ('apple', 5)
002 | ('pear', 8)
003 | ('banana', 10)
!e py d = {"apple": 5, "pear": 8, "banana": 10} for key, value in d.items(): print(key, value)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | apple 5
002 | pear 8
003 | banana 10
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
thank you
so i guess i need 50 messages
@somber heath How's it going
!voiceverify
yeah i have fewer than 50
so anything you guys are currently working on
I think I solved a leetcode problem that did that
hey r any of u well versed w opencv
class Simulation:
def __init__(self):
self.videosource = VideoSource()
self.projectiletracker = ProjectileTracker()
videofeed = self.videosource.GetVideo()
# cap = cv2.VideoCapture('Videos/v2.MOV')
#self.detectprojectile = self.projectiletracker.DetectProjectile(self.videofeed)
cv2.imshow("Image", videofeed)
class VideoSource:
def __init__(self):
pass
def GetVideo(self):
print('Type in the name of the video file you wish to upload.')
print('Press \'W\' if you wish to access the webcam instead.')
vidinp = input()
if vidinp == 'N':
self.vs = cv2.VideoCapture(0)
else:
self.vs = cv2.VideoCapture(vidinp)
self.frame = self.vs.read()
return self.frame
!voice @jolly python
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
@somber heath dw, im currently trying to understand debugging. Im quite new to python so i thought i could really use some help
Im currently trying to do an assignment, fixing broken code. It contains a lot of syntax errors, which i dont understand.
sure where can i do that
!code
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.
ahhh
print("Hello, world!")```
def main():
decimals = {1, 4, 5, 9, 10, 40, 50, 90}
{100, 400, 500, 900, 1000}
numerals = {"I", "IV", "V", "IX", "X", "XL",
"L", "XC", "C", "CD", "D", "CM", "M"}
position = len(numerals - 1)
number = user_input
while number:
div = number // decimals[position]
number %= decimals[position]
while div:
print(numerals(position), end="")
div -= 1
position -= 1
def user_input():
input_string = input('NatΓΌrliche Zahl > ')
while not input_string.isdigit():
input_string = input('Eingabe muss eine natΓΌrliche Zahl sein > ')
return int(input_string)
if __name__ == '__main__':
main()
NatΓΌrliche Zahl is just an int
bruh wait i just noticed i posted the wrong code
this is the version ive been tinkering on
let me send the original one
def main():
decimals = {1, 4, 5, 9, 10, 40, 50, 90,
100, 400, 500, 900, 1000}
numerals = {"I", "IV", "V", "IX", "X", "XL",
"L", "XC", "C", "CD", "D", "CM", "M"}
position = len(numerals - 1)
number = user_input
while number:
div = number // decimals[position]
number %= decimals[position]
while div:
print(numerals(position), end="")
div =- 1
position -= 1
def user_input():
input_string = input('NatΓΌrliche Zahl > ')
while not input_string.isdigit():
input_string = input('Eingabe muss eine natΓΌrliche Zahl sein > ')
return int(input_string)
if __name__ == '__main__':
main()
this is the original one
what does set do again?
hasheable?
ahh
okay
thank you
ok
may also include run time errors
since its currently not running
im getting an error, "object set is not calleable"
!epy a = {1, 2, 3} a()
@somber heath :x: Your 3.11 eval job has completed with return code 1.
001 | Traceback (most recent call last):
002 | File "<string>", line 2, in <module>
003 | TypeError: 'set' object is not callable
im getting this error message now: unsupported operand type(s) for -: 'set' and 'int'
!e py {1, 2, 3} + 4
@somber heath :x: Your 3.11 eval job has completed with return code 1.
001 | Traceback (most recent call last):
002 | File "<string>", line 1, in <module>
003 | TypeError: unsupported operand type(s) for +: 'set' and 'int'
!e py a = {1, 2, 3} a.add(4) print(a)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
{1, 2, 3, 4}
okay
im going to continiue trying to fix it, i have another question regarding python
what does the return statement do
for example
if i put it lie this:
def text:()
print("Text")
text()
if i put it like that i get a print
but
if i do
x=5
y=2
def calc:(x, y)
result=x+y
return result
print(result)
!e ```py
def func(): #not the call
return 5
v = func() #func() here is the call
print(v)```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
5
This is like writing
v = 5```
The object you give to return rrplaces the call to that function.
All callsbles that complete, return. If nothing is given to return, the object None is instead returned.
!e ```py
def func():
pass
v = func()
print(v)```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
None
!e py result = print("Hello, world.") print(result)
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | Hello, world.
002 | None
This shows the difference between printing and returning.
!e ```py
def func():
print("Hello, world.")
return 5
print(func())```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | Hello, world.
002 | 5
!e ```py
def add(a, b):
return a + b
result = add(5, 2)
print(result)```
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
7
so there is a difference between variables and parameters
parameters dont need to be defined first
hmmm
im just used to defining variables first and not defining them after
right
so return says what the output of a function is again
my brain has become mush
im trying to wrap my head around this
!return
Return Statement
When calling a function, you'll often want it to give you a value back. In order to do that, you must return it. The reason for this is because functions have their own scope. Any values defined within the function body are inaccessible outside of that function.
For more information about scope, see !tags scope
Consider the following function:
def square(n):
return n*n
If we wanted to store 5 squared in a variable called x, we could do that like so:
x = square(5). x would now equal 25.
Common Mistakes
>>> def square(n):
... n*n # calculates then throws away, returns None
...
>>> x = square(5)
>>> print(x)
None
>>> def square(n):
... print(n*n) # calculates and prints, then throws away and returns None
...
>>> x = square(5)
25
>>> print(x)
None
Things to note
β’ print() and return do not accomplish the same thing. print() will only print the value, it will not be accessible outside of the function afterwards.
β’ A function will return None if it ends without reaching an explicit return statement.
β’ When you want to print a value calculated in a function, instead of printing inside the function, it is often better to return the value and print the function call instead.
β’ Official documentation for return
!tags scope
Scoping Rules
A scope defines the visibility of a name within a block, where a block is a piece of python code executed as a unit. For simplicity, this would be a module, a function body, and a class definition. A name refers to text bound to an object.
For more information about names, see !tags names
A module is the source code file itself, and encompasses all blocks defined within it. Therefore if a variable is defined at the module level (top-level code block), it is a global variable and can be accessed anywhere in the module as long as the block in which it's referenced is executed after it was defined.
Alternatively if a variable is defined within a function block for example, it is a local variable. It is not accessible at the module level, as that would be outside its scope. This is the purpose of the return statement, as it hands an object back to the scope of its caller. Conversely if a function was defined inside the previously mentioned block, it would have access to that variable, because it is within the first function's scope.
>>> def outer():
... foo = 'bar' # local variable to outer
... def inner():
... print(foo) # has access to foo from scope of outer
... return inner # brings inner to scope of caller
...
>>> inner = outer() # get inner function
>>> inner() # prints variable foo without issue
bar
Official Documentation
1. Program structure, name binding and resolution
2. global statement
3. nonlocal statement
hmm
so what happens inside a function wont bother the rest of the code only its ouptut
in that case
if i ask my friend what is 5+2
it does not matter what happens in his brain
but it matters what he tells me*
ahh
allright sleep well
Hey
@strong ivy @gritty schooner π
!code
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.
@tidal shard
what type of api?
and which framework
ohh
that's what i was thinking
a year ago
soo
what is an API
a/c to u
ohk ohk
while True:
x=int(input())
y=int(input())
z=int(input())
listan=sorted([x,y,z])
print(str(listan))
boo=listan.append(input())
if boo==("X"):
print("sada")
thats it so far.
Initialise your list outside of the while loop.
Accept user input inside the while loop.
i cant get it to work
Post your code.
while True:
x=int(input())
y=int(input())
z=int(input())
list=sorted([x,y,z])
B=list.append(input())
if B==("X"):
break
print(str(list))
i know you said start the list before the while loop
but even that is something im not sure of how to do
@somber heath
How would you create an empty list instance?
list=[ ]
Yes, but don't use list as a name. It's a reference to the builtin list class.
So you don't want to overwrite that.
What is the purpose of list.append?
Adds a thing to a list.
What do you want to do an arbitrary number of times?
Add a thing to a list.
How do you do things an arbitrary number of times? You do it in a loop.
hence why the append is in the while loop
You've got too many calls of a particular function.
Would you care to guess which?
You only need to write it once.
x y z
Colder.
smooth brain moment rn ngl
What is the purpose of the loop? To ask for user input, check whether you entered a number or an x, then append or break accordingly.
!voice
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
@whole bear π
heyy i coulduse some help
i just started with a book called python crash course and im trying to add a white space into my code but it gives me a error
Show the error message.
and i cant seem to get the >>> into my code? i'm quite new to this
The >>> is the REPL prompt.
okayy so how do i get that?
Can you see sometging that says terminal or console?
yeah im using sublime text atm and the terminal is right under my code, what im basically doing is just learning the basics of python
also how do i get permission to speak on the server?
!voice
Voice verification
Canβt talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.
f-strings
and this, opalmist, is why you delete the command after posting it
!e py age = 17 name = "Peter" print(f"Hello, {name}. You are {age} yeads old.")
@somber heath :white_check_mark: Your 3.11 eval job has completed with return code 0.
Hello, Peter. You are 17 yeads old.
I'm here, just knocking out some stuff that's asap
!e
Just couldn't remember if this works or if you have to explicitly convert the age to a string
name = "Steve McSteveson"
age = 45
print("Hello, ", name, ". You are ", age, " years old.")
@rugged root :white_check_mark: Your 3.11 eval job has completed with return code 0.
Hello, Steve McSteveson . You are 45 years old.
Shape the medieval landscape of France, claiming cities, monasteries and farms.
@quasi condor For context of what it's like
Ship goods, construct buildings, and choose roles that benefit you more than others.
the history washing is little meh
Ooooo, forgot about that one
I do remember liking it
It's like Cataan but without the board, right?
No, it's just different, my biggest like of Puerto Rico is everyone is playing every turn
JUST LET ME FINISH THE CITY FOR GOD'S SAKE
In your face 90's technology!
Itβs interesting from βthis is where we startedβ but not much else. Being able to run it doesnβt add much IMO.
Totally agree. A calculator can run this stuff.
I don't know what your talking about, I am being crushed by solitaire ATM
@quasi condor do people actually use rhyming slang
not any more
hi
@zenith radish what in the fuck
This has context. It's a Mahjong game site
no this is from a different website
Oh that's from your site, right
yeah
@prisma ingot Check out the #voice-verification channel
That'll tell you what you need to know about the voice gate system
https://www.glassdoor.co.uk/Salaries/zurich-software-engineer-salary-SRCH_IL.0,6_IM1144_KO7,24.htm
https://www.glassdoor.co.uk/Salaries/san-francisco-software-engineer-salary-SRCH_IL.0,13_IM759_KO14,31.htm
The average salary for a Software Engineer is Β£108,698 per year in Zurich, Switzerland. Click here to see the total pay, recent salaries shared and more!
The average salary for a Software Engineer is Β£143,757 per year in San Francisco, CA. Click here to see the total pay, recent salaries shared and more!
108CHF = 114usd
@limpid sparrow The keyboard I have
https://www.glassdoor.co.uk/Salary/Google-Software-Engineer-Salaries-E9079_D_KO7,24.htm
https://www.glassdoor.co.uk/Salary/Microsoft-Software-Engineer-London-Salaries-EJI_IE1651.0,9_KO10,27_IL.28,34_IM1035.htm
73k at Google vs 60k at Microsoft
ger-nome
If I didn't have morals I'd work at this company
Move to Palantir
And then leave and start a new company
Orthanc
oculus founder
Wait, what's his... the one with the weird name
Anduril is a defence technology company, bringing Silicon Valley talent and funding to the defence sector. Our technology helps our customers solve their toughest challenges by enabling them to make better, more informed decisions in life-and-death situations. Weβve assembled a diverse team of experts in artificial intelligence, computer vision,...
Discover Skeyetech, our innovative security drone solution. Skeyetech is an autonomous drone designed for sensitive sites protection.
Anduril Industries is a defense technology company with a mission to transform U.S. and allied military capabilities with advanced technology. By bringing the expertise, technology, and business model of the 21st centuryβs most innovative companies to the defense industry, Anduril is changing how military systems are designed, built, and sold. A...
The term United States person or US person is used in various contexts in US laws and regulations with different meanings. It can refer to natural persons or other entities.
@stray niche @limpid sparrow Yeah sorry, there's a certain combo of people that almost guarantee that things get heated. As voice lead, I apologize.
No, you don't have to
Maybe fix bad attitudes before expecting to get a proper job π
Be back in a bit, talking with the HVAC folks
i wanna output this airflow.cfg into my windows folder with cp command does anyone know how could i do it ?
blah why do I need to send 50 messages to talk in voice 
So we had what I call hit and run trolls. They would join the server, join voice chat, scream, and then leave
This was happening like.... 6 or 7 times a day
have you tried running cmd as administrator?
50 messages over three 10 minute blocks shows (ideally) interaction with the community, and the 3 days will typically make it not worth a troll's time.
50 messages is a lot lol - I'm a fairly reserved person and don't typically type unless I have something especially pertinent to say
Suck it solitaire:
And that's fair, but that's why we encourage folks to engage in the conversation here. Most people in VC will be watching the paired text channel
3 card draw Klondike?
yes
There are so many games that aren't actually winnable
so many restarts....
the solution is to think of many pertinent things
*many especially pertinent things
A strange game. The only winning move is not to play
like russian roulette
Sure but where's the fun in that?
that's loser talk
by definition it is winner talk
quantum superposition winner+loser+spectator
compose does not survive restarts I believe
https://forums.docker.com/t/how-to-handle-server-reboot-when-using-docker-compose/26374 Not sure if that's relevant @amber raptor
When using docker run for a single container, I understand that I can assign a restart policy to make sure the container is restarted by docker when the server reboots. What is the equivalent practice when using docker-compose for all services defined by the docker-compose.yml? If I stand up several services as containers using docker-compose,...
the best way to get the right answer is to proclaim the wrong answer as correct
It should be able to take care of that on its own I thought
Just want all the containers in a single compose file to restart on reboot?
No it isn't!!!
just run code on your viewers' side to transcode for you 
The real correct answer is - [...]
ah, I've been proven wrong, woe is me
k8s
secretary fascination
I want one too 
whiteboards reinforce hue stereotypes 
Yo
imagine if you hired an ex-MBA
@rugged root Haaaalp
?
Look at this shit
[...], please allow up to 24 hours for your Multi-seat subscription to be activated.
I placed the order on Wednesday
My users are unable to work without it
Call them?
I sent an email
That'd be I'd try to find
You used the chat thing in the bottom right of their site?
i like phones
Sent an email to the address in the directions
When
Doesn't look like chat would be any faster
This morning
Automated response said "probably within four hours"
Heck these people
I already only have to buy it because Pantone and Adobe are in a bitch fight
They're both global companies
that pantone situation is everything wrong with closed-source software
They could have someone in another location approving things
I'm still confused with all that
Regardless, there's no excuse for not automating things or forcing me to jump through hoops to "convert" a "personal" account to a "business" account
https://www.youtube.com/watch?v=qMWAY8Cdsz0
The company that gets to decide what a color actually looks like gave Adobe an "all access" license to Adobe to allow all of Adobe's users to use those colors in their products.
They got bitchy about some licensing crap, and revoked the license.
Adobe users are now unable to use colors in their software.
They're now forced to pay the color company a monthly fee to add these colors back into their programs
TEAMGROUP's Black Friday/Cyber Monday Sale: https://bit.ly/3FffwDC
TEAMGROUP Delta RGB DDR5 6400 - White at Micro Center: https://bit.ly/3CGMObR
Buy a Seasonic Prime TX-1600: https://geni.us/TBRYP9U
Pantone recently decided that their expensive plastic chips and colour matching binders were not making enough money. Now, even old files will sto...
OOH me too
π΄ββ οΈ π¦
Does make me wonder like.... is it certain hex codes are limited?
Just unsure how all that works
it seems like instead of putting an rgb/hsv/... color to something you give it a pantone designation
Anyone ever play Fortune Street?
so the rgb/hsv/cmyk actual color changes depending on the medium it is printed in, which is pantone's tech
so they patented a lookup table 
That.... kind of makes sense
"valorant was a mistake"
Literally just
colors.update({
"11-0907 TCX":"F0DFCC"
})
Which is why it's so hecking infuriating that I now have to pay for it
Weird
AND NOW YOU HAVE TO HAVE AN ACCOUNT JUST TO SEE THE COLOR PICKER ON THEIR WEBSITE

This company is getting on my nerves
Oh huh
Little long... Okay, a lot of long, but it has some good parts. It's a fuuuuuuun game, let me tell ya.
Forgot that I actually recorded a few sessions of it
Wow that was a really long game.... They don't usually run that long
emacs 
furiously typing for 20 seconds = #!/bin/bash
what is wrong with lex fridman
Board Game Online is an incredibly weird multiplayer game. Join the fun and play for free in your browser with friends or strangers! No account required!
I've run out of useful things to say
I will now live-blog what I'm working on
modifying some internal docs for k8s process
What are the conditions for getting video role? How can I get a video role?
@rugged root
there is a different video role?! how much DKP does that cost?
In fact, what role is needed for screen sharing?
Usually it's just ask me. Typically I'll grant it on a temporary basis as needed, and if I get more comfortable with someone, I'll give them a probationary period where I grant it to them for 3 weeks
Okay thanks, sir.
How about screen sharing?
Oh that's how you do it, it's role bound
So I temporarily grant the role, thus giving perms
I joined this server in 2018, and can't chat in vc 
I got it. Thanks.
Let me check your stats real quick
Ah right right
We had people streaming porn. I'm not budging on having that restricted
@real solstice
You can go there and verify your voice.
God I love Sublime
@quasi condor did you scare everyone off?
@whole bear #voice-verification will tell you what you need to know about our voice gate
okayy so i have to send like 50 messages in order to get voice vertication
spinnekop is like a spider incase you didnt know XD
afrikaans :)
I bought the Python crash course book
eric matthes
yeah im really new to this, are you guys very experienced?
yeah i want to get a job here in south africa, thinking of changing my career
Aluminium windows and doors but its quite labour intensive and I want more money i get like R4.400 a month
yep
so i have to teach myself to code basically, python is much bigger in the US than here in SA but if I don't learn python I won't have a good foundation
#C is what the people use here
yes C#
Do people get jobs there in the US without a CS degree?
I see, yeah I dont have the money to get a degree nor was my points good at school lol
The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.
Thanks alot I appreciate it
@mortal eagle
so what do you guys do for a living?
oh cool
yeah, I here trades are in demand in the US
I was considering building
XD
my dad makes like 28k a month, which to me is not good enough
rand
18 rand to the dollar
i always see these videos of greg secker, do you guys know him?
Doesn't ring a bell
its this dude that does videos of teaching people how to trade online, like forex trading
like there must be some kind of catch lol
oh yeah? is it legit?
id rather start a busniss than do crypto
it's not even that hard xd
just knowledge (alot of knowledge)
alot of exp alot of patience and risk management
alot
Spider, how old are you if you don't mind me asking?
23
@rugged root will you do my work for me
I'm not that smart
nvm figured it out i didnt put in quotes
So you're missing a few quotes to indicate which things are - yep
im not either i literally can't even run our code it's been a week
Eh, setup is always a bitch
this waveform wasn't there because I was using the web-version of Discord.
i have a deadline tomorrow to finish implementing a project
yeah I'll never have kids
ah
now I'm using the desktop one
in our country if you have kids your life is as good as gone
Back in a bit
big-tech companies suck
i see plenty of people get pregnant like its a game they dont understand what living costs are like
microsoft sucks. but i use xbox
google sucks. but i use youtube
SAP SE (; German pronunciation: [ΙsΚaΛΛpeΛ] (listen)) is a German multinational software company based in Walldorf, Baden-WΓΌrttemberg. It develops enterprise software to manage business operations and customer relations. The company is the world's leading enterprise resource planning (ERP) software vendor. SAP is the largest non-American softwar...
OECD's dissemination platform for all published content - books, podcasts, serials and statistics
@uneven yarrow hello
my voice not verified cant talk vc
the 50msg left
maybe 10 or something
ok
nope
nope ..
im asian
It wasn't me this time - I was scared off myself and went to bed
"this time"
Twice in a day would be a bit much
print('Albert Einstein once said, "A person who never made a mistake')
print('never tried anything new."')
can someone explain why it outputs this
Albert Einstein once said, "A person who never made a mistake
never tried anything new."
basically what are the single qoutes used for?
they're equivalent to double quotes
if you need to include a double quote in a string you obviously can't use double quotes to enclose it
print("she said "hi" then walked on") will give an error
so will
print('she said 'hi' then walked on')
because you're closing your opening double quote halfway through the sentence
but if you do
print("she said 'hi' then walked on")
or
print('she said "hi" then walked on')
you won't have the error
because you aren't closing your opening quote until the end of the string
@whole bear
so basically in a nutshell you cant use double qoutes twice within a string?
same for single quotes
but if your string is enclosed with single quotes it can contain double quotes
and if your string in enclosed with double quotes it can contain single quotes
I understand now
also i have anoither question, why do integers that you divide always have decimals? is there a way to change this?
print(4+4)
print(4*2)
print(14-6) and the last one with / I cant seem to get working properly
because the result of dividing two integers is a float
!e
top = 8
print(f"type of top is {type(top)}")
bottom = 4
print(f"type of bottom is {type(bottom)}")
result = top/bottom
print(f"result is {result}")
print(f"type of result is {type(result)}")
int_result = int(result)
print(f"integer result is {int_result}")
print(f"type of integer result is {type(int_result)}")
@gentle flint :white_check_mark: Your 3.11 eval job has completed with return code 0.
001 | type of top is <class 'int'>
002 | type of bottom is <class 'int'>
003 | result is 2.0
004 | type of result is <class 'float'>
005 | integer result is 2
006 | type of integer result is <class 'int'>
does that help @whole bear
