« first day (2824 days earlier)      last day (2127 days later) » 

3:00 PM
@DSM Urgh yeah. I was tempted to pick up Go for more intensive stuff. Maybe it's come forward now, but Julia always seemed a bit immature/unsupported for me. I don't tend to do much low-level pure maths stuff myself, instead I'm working at a higher-level with libraries to put stuff together.
 
DSM
@Ffisegydd: I wouldn't recommend Julia yet to Joe-on-the-street -- your impression that the community's still immature is still fair, I think, although a lot less than it used to be -- but I have to admit I love being able to do jitted metaprogramming.
@modiX: nothing comes to mind. I just know that even now, though I know better, I sometimes find myself reaching for a bash script because I know I can get the 90% solution done slightly faster. I would never put a non-trivial bash script into production, though.
 
One thing to watch out for, if you're expecting Python to be on all systems (or easily installable) then that's true, but bear in mind different versions. Older versions of Linux will have 2.6 or 2.7. The latest version is 3.7, and there are changes to bear in mind between 2 and 3.
 
Who's Julia and why wouldn't Joe like her? :p
@Ffisegydd umm... most linux distros I've used have 3.5 at least these days
 
Yea if Julia had the support of some other libraries I would switch, granted the last time I looked into it was almost a year ago.
 
Mate I mostly work on CentOS :P
It's still something to bear in mind.
 
3:09 PM
sorry to hear that mate :)
 
DSM
At least CentOS is somewhat closer to modernity than RHEL proper.
 
Even 3.5 vs 3.7 there are changes though, right? Basically don't anticipate all systems to have 3.7.
 
oh... I'd not expect anything to have 3.7 for a while yet...
 
Is 3.7 not out yet? As I say I WORK MOSTLY ON CENTOS! :P
I think I've got 3.5 on my dev boxes
 
DSM
3:11 PM
I'm not going to jump myself until it's easy to install the whole ecosystem.
 
I've pushed the team to use Anaconda nowadays. We've got ansible playbooks to set up dev environments and we install Anaconda 3.5 by default.
 
Proposal to change equality checks to use unicode's 2A75 ⩵ TWO CONSECUTIVE EQUALS SIGNS
 
DSM
For the love of all that's holy, please don't suggest that to Guido.
 
Perfection in programming languages is attained when nobody can actually write a syntactically valid program
 
DSM
Code that can't run experiences no bugs. #embracethetao
 
3:22 PM
@Ffisegydd f-strings and ordered dicts \o/
 
Maybe if you use 2A6B ⩫ TILDE OPERATOR WITH RISING DOTS it could just call __repr__ on both objects and compare the strings
 
@DSM Coming from batch I really hate bash for its syntax. Python is so much more readable. @Ffisegydd This is an interesting point regarding different versions. I will keep that in mind when I write scripts for exotics.
 
brb, creating a new golfing language that maps the top solution on every PPCG question to the next unused unicode character
 
rb folks
 
>>> open(0).read()
load: 1.14  cmd: python3.6 43784 waiting 0.02u 0.00s
Why to I see this output when I open stdin and press ^T?
*do, whoops
 
3:38 PM
morning cabbage
 
cbg
 
@modiX yes, batch syntax is terrible
 
4:01 PM
Going through my comments oldest first, it's always great seeing the off-topic questions I answered when I was new. :-/
 
I hate bash, not batch, but in conclusion, both are terrible xD
 
had easier times with batch, tho
 
4:14 PM
@AnttiHaapala gosh, and Unutbu is #1. Something to be proud of! :-P
 
cbg
 
@Martijn didn't someone put as a burnination request on meta?
 
no idea.
 
@smci was in here asking for opinions on from the python point of view -- link
here's the relevant retag-request
 
4:40 PM
ah nice
I still don't understand the case E :D
 
cbg
 
5:00 PM
hi, in Django I've registered a receiver with both the pre_save and post_delete Signals, how can I know which Signal has been received so that I may execute a different block?
 
Any reason you can't have two separate functions registered one for each signal?
 
Just wanted to keep things short
 
branching on the type of signal doesn't really make it shorter... it just makes it one block of code that's less obvious than two clearly defined handlers, no?
 
I guess, thanks
 
One of these days I really need to make a "how come my tkinter program, which contains an inescapable while True: loop, keeps freezing?" canonical post
 
5:08 PM
or why does assert False fail?
 
golf challenge: print every valid IPv4 address
 
Zero points for print("every valid IPv4 address")
 
is it acceptable to print more than that
 
uh, no sound like a more fun answer
 
I got as far as for t in __import__("itertools").product(range(256),repeat=4):print(".".join("{:02X}".forma‌​t(x) for x in t)) before I became unsure whether every conceivable combination of four two-digit hex numbers is a legal address
 
5:15 PM
Hello all. I've been looking about to make a service that will run as it's own process, and multiple other classes can interact with it. Imagine a queue that has many contributors. Can someone please guide me a little?
 
82 bytes. I wasn't patient enough to wait for it to actually print the result, but it should work
 
Like maybe 255.255.255.255 is illegal idk
 
also, I think 001.2.2.2 as well as 01.2.2.2 as well as 1.2.2.2 are legal
 
I was considering anything that would resolve the same as the same
 
recbg
 
5:21 PM
recbg
 
@Aran-Fey 57: for i in range(1<<32):print(*i.to_bytes(4,'big'),sep='.')
 
import ipaddress as i
for i in i.IPv4Network('0.0.0.0/0'):print(i)
can be golfed to smaller if you've got terabytes of ram :d
 
ram and performance doesn't matter when golfing
 
@AndrasDeak but you need to verify...
otherwise I'd golf
print(*__import__('ipaddress').IPv4Network('0.0.0.0/0'))
which beats @vaultah by one character :P
or no... :F
 
Yes
 
5:27 PM
just put it in does_it_halt()
 
was missing one _ in my dunder :F
though mine is space-separated
print(*__import__('ipaddress').ip_network('0.0.0.0/0')) one less :P
I guess that's 55
 
print(*__import__('ipaddress').ip_network('0::0/0'))
Or print(*__import__('ipaddress').ip_network('::/0'))
But it is ipv6?
 
Sam
I've got a list of objects in which I want to iterate over and calculate the mean value... is this the most efficient way of doing so? I'm trying to avoid using for loops and this is the best I've come up with. The code works fine but I think I've read previously that I should avoid using iter in Python 3? (I may be wrong)
print(sum(z.prglength for z in a.records.__iter__()) / len(a))
 
don't use dunder methods like that
 
5:41 PM
You almost never want to invoke a double-underscore method directly. Oops beaten
 
for z in a.records should implicitly use iter(a.records) which calls a.records.__iter__()
 
Sam
Glad I asked XD
 
also...
you're doing it wrong :d
 
Sam
Probably :p
 
perhaps...
depending...
 
5:42 PM
How so?
 
Sam
I'm all about those 1 liners
 
statistics.mean(z.prglength for z in a.records)
could be numerically more stable
 
no, because it needs .prglength for each item
 
Probably not worth the effort to avoid using a for loop here, since the solution is almost certainly going to be O(N) anyway
 
ah :d
 
Sam
5:43 PM
What I'm doing is list comprehension right?
 
@Sam no.
gen. exp.
 
it's better
 
is there a difference between "for x in a" and "for x in iter(a)"
 
same logic as a listcomp but it doesn't actually create a list
 
statistics.mean converts its argument to list if it's an iterator: github.com/python/cpython/blob/3.7/Lib/statistics.py#L307 @AnttiHaapala
 
5:44 PM
or does "in" know that it should use iter
 
@MoxieBall there is.
 
well :D not really :P
 
Define "difference"
 
someone give Antti some salmiakki, his blood sugar is low
 
5:45 PM
Is there ever a scenario where "for x in iter(a)" works and "for x in a" doesnt?
 
except for x in a will call a.__iter__()
so you do iter(iter(a))
 
Sam
I want to avoid using module methods (purely for learning purposes). Performance aside
 
@Sam you should be slapped then.
 
Nothing comes to mind, assuming you don't rebind iter to something silly
 
I hoped as much, just making sure
 
5:45 PM
avoiding module methods are only done to exploit a security hole in eval that doesn't allow statements
 
what Antti said
 
that's bout the only time you need this here.
other than that, the iter() call is implicit in for anyway.
 
Unpopular opinion: I think reinventing the wheel is a fun and educational exercise. Just don't do it in code intended for public consumption.
 
yeah, it's fine for learning, this would otherwise be a good use case for a genexp
 
Sam
@Kevin Thats how I learn at least :)
 
wim
5:48 PM
@AnttiHaapala not always, because a.__iter__ might not even exist
 
Sam
@AndrasDeak genexp?
 
short for generator expression
 
"generator expression". Oops beaten
 
(what you already have)
 
Sam
Kevin you need to up your typing game
 
5:49 PM
Let's discuss the current geopolitical climate (you can't escape Kevin...)
 
Only nine more and Andras gets a free sandwich and medium soda
 
it's an honour to Kevin Kevin
 
@Ffisegydd brb gonna hide in the js room until this all blows over
 
Where you go I cannot follow.
 
But this is rather like drinking poison to escape pursuit
 
5:52 PM
@wim ah that's true :D
I was going to write iter(a) :f
>>> '123'.__iter__
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'str' object has no attribute '__iter__'
>>> iter('123')
<iterator object at 0x7f3d51c13410>
@Sam ^
 
wim
better :)
 
pyt
hon
2
>>> class Foo(object):
...     pass
...
>>> iter(Foo())
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'Foo' object is not iterable
 
wim
regarding the IPv4Network thing... I showed how to use it on How to increment at different intervals python? and got downvoted :-\
 
>>> class Bar(object):
...     def __getitem__(self, i):
...         return 'item %d' % i
...
>>> for i in Bar():
...     print i
...
@wim countered
 
wim
__getitem__ iteration is still here in Python 3.7
 
5:57 PM
for i in range(255*2): next(gen) though?
 
Sam
@AnttiHaapala So just iterate over the returned iter() object?
 
wim
@AnttiHaapala thanks
 
it does but I was lazy to exit python 2 since it had happened already
Wow exactly what I was looking for thank you! — unixcycle Jun 27 at 20:25
now I get it, yours doesn't work for up to 192.168.1.999
 
wim
feature not a bug :P
 
The 'it was just an example' @me was in response to asking why he wanted to go to 999...
 
6:00 PM
I'm surprised that it's possible to iterate over an object that implements __getitem__ but not __len__.
From the glossary's definition of "sequence" and "iterable" I'd expect __len__ to be necessary
Does it count as a bug if the documentation requires you to implement a method, but the actual implementation doesn't?
 
yes, but it's unclear what exactly is buggy
also check if pypy and jython do the same thing :P
 
I just typed in a whole long question and through the process of typing it in I realized the answer so thanks for the non help.
 
6:16 PM
I'm always happy to not give out help
also I'm not sure what "non help" you're talking about
unless it's non help in a question you haven't even asked yet which would make the most sense given context
 
@AndrasDeak Thanks for not answering the question I didn't ask, because I figured it out myself.
 
OK, no worries
 
Sam
Take the credit
Bathe in it
 
I was just thrown by the mildly passive agressive vibes from your original message
it's fine in hindsight
 
6:21 PM
@AndrasDeak Twas unintentional. My apologies.
 
Having a huge memory lapse here, is there a way to do something like itertools.product except with certain positions constrained?
for instance if we have [3, 4, 2] then the first element only iterates over 0-3, second over 0-4, third over 0-2
 
cbg
 
Yeah, product can do that
 
product(*map(range,[3, 4, 2]))
brb suppertime
 
Afternoon cabbage
 
6:33 PM
@vaultah Nice.
 
afternoon
 
Evening
 
i'm a little stuck... i am trying to read from a CSV file, and access the values from the first column , in this way
import csv

backupid_dict = dict()
with open("excel.csv") as f:
reader = csv.DictReader(f)
row_list = [r for r in reader]

if row_list:

for row in row_list:
print row.backupid
but it's not working, can you point me in the right direction
 
row['backupid']
 
@AndrasDeak Thanks, that's pretty awesome
 
6:37 PM
this is python 27 also if that makes a different
thanks ill try that
 
Also, you should open the file in binary mode. The csv reader needs it like that.
 
Also list(reader)?
 
And no need for the if row_list: :)
 
hmm i have this now:
import csv

backupid_dict = dict()
with open("excel.csv", 'r') as f:
reader = csv.DictReader(f)
row_list = [r for r in reader]

if row_list:

for row in row_list:
print row['backupid']
but it just returns nothing when i run the program
oh i will check and come back, the dictionary is empty for some reason
 
Strange, works on my machine:
c:\Users\Kevin\Desktop>type excel.csv
foo,backupid
1,2
3,4
5,6
c:\Users\Kevin\Desktop>type test.py
import csv

backupid_dict = dict()
with open("excel.csv", 'r') as f:
    reader = csv.DictReader(f)
    row_list = [r for r in reader]

if row_list:
    for row in row_list:
        print row['backupid']
c:\Users\Kevin\Desktop>py -2 test.py
2
4
6
If our code is identical, then the most likely remaining possibility is there's a problem with your .csv file
 
6:45 PM
thanks very much Kevin I will re-check it
 
Hi Guys good evening!
 
thanks Adras
 
Hello Guys, I am trying to add Journal File code to my Python Script. I'm not sure if this is the correct Pythonic Term used. But, I am using this, in case if my script encounters any error and store those error iterations in a file but still execute the whole script. Does anyone have any idea about this? Can anyone guide me to the correct blog or article to know more about it please.
 
I have the following problem: My code goes through about 9000 txts and 7000 xmls and makes it from certain information a large JSON file. I follow the passage through prints in the console. At a certain time, the code starts to work more slowly, although the same structure and task must be done in each file. What can this be?
 
6:48 PM
perfect Kevin... the csv file had become corrupt in earlier iterations of me trying to solve it, now it's working with that code thanks
 
@madik_atma out of memory -> thrashing?
Or looping over containers that get longer and longer
 
@KaranM The term for recording information about errors (and other messages) is "logging". The term for recovering from ordinarily fatal errors is "exception handling". You should be able to find lots of resources concerning these topics.
 
It's a function that runs a big for loop over the files and there are several for loops. (XML parsing) @AndrasDeak
 
@Kevin Okay, So I am able to see there is lots of information on JournalHandler module as well. Is logging and Journal both nearly similar?
 
the previous script used this code:
' command_with_parameter = (command_template % row.backupid)
can i use row.backupid with the dictionary i created a bove should it work ok, with the dot syntax would you say
 
6:53 PM
I've never heard about JournalHandler before, so I don't know
 
@Kevin Okay! I'll do some research on logging Thanks :)
 
@Gary An ordinary dictionary doesn't let you access keys like that, no. row['backupid'] is the conventional syntax.
 
@madik_atma OK
 
@Gary Also, you can remove row_list and just do for row in reader:
 
6:55 PM
@AndrasDeak what would you suggest?
 
@madik_atma finding the source of the problem
 
@AndrasDeak Thanks. I'm having a difficult time of it today
 
no problem
 
fortunately you warned me soon enough that I could edit it
 
if row_list:
                # Execute command for the first 10 items found in the sorted list.
                i = 0
                for row in row_list:
                    # Create command using the backup id
                    command_with_parameter = (command_template % row.backupid)
                    # Display the command.
                    print('Executing command: ' + command_with_parameter)
                    # Execute the command.
                    os.system(command_with_parameter)
 
6:56 PM
+1 on the indentation, thanks
 
this was the original code ; i'm just trying to use the dictionary i created above, with this
`command_with_parameter = (command_template % row.['backupid'])
should this work do you think
 
@AndrasDeak ? is this now funny, or what? I am here to find a solution for my problem, here are many talented guys, and you suggest me I should find the source of the problem. Are you just hanging around here to give some "cool" answers?
 
I already gave you suggestions which you promptly ignored. What else should I do?
 
@Gary it's hard to tell without an example value for command_template
 
I have googled it, thank you for your suggestion. But this "finding the source of the problem" answer to my question is not nice. Thank you.
 
6:59 PM
it's exactly as nice as ignoring responses to your request for help :)
 
@madik_atma Unfortunately, resource leaks tend to be difficult to debug even with a 100% clear picture of the code. Based on the limited information available to us right now, the best advice we can give is pretty dang generic
 
@madik_atma we can't really do much to help you with your question, besides suggesting that you monitor your memory usage or run some other tests to figure out exactly which part is causing it to run slower, then maybe we can answer why
 
that question was a joke.... right?
 
he never jokes
 
7:02 PM
@Gary You've got a stray period there. Try command_with_parameter = (command_template % row['backupid'])
 
@AndrasDeak Yes ^a is anchor pattern and a$ is ending pattern
 
@madik_atma When I ask questions, if someone answers, I am very thankful. Often times people just don't. They just might not be able to answer your question.
 
I'm glad we sorted this out.
 
Also sometimes really smart people are sassy.
 
andras is the man of c00l
c00l answer, andras
 
7:06 PM
> The first thing you need to know to get out of recursion land is how to get out of recursion land
Words of wisdom from my boss
 
recursion land looks a lot like tautology land
 
It's easy to escape from Python's recursion land, just go 999 layers deeper
The real danger is trying to execute fibonacci(990), which executes successfully after a mere billion billion years
 
or if you're in a pocket universe where stackless python is a thing I thought stackless was defunct but their github seems active
I vaguely remembered a remark here along those lines but I probably misremember
 
I mostly just pretend that only CPython exists, it's easier
 
user10043886
7:31 PM
Hi. I have an array like this: `statevector = [3,4,6,8]` and another like `array_mask
=array([0, 1, 0, 1])`. When I type in `statevector[array_mask != 0]`, it says `TypeError: only integer scalar arrays can be converted to a scalar index`. However, [this program](https://github.com/nelimee/quantum-tools/blob/master/HHL/4x4_system.py#L58) executes fine. I can't understand what the problem is
 
For what it's worth, only one of those is an array. statevector is a list.
I usually let that kind of terminology slide but it might actually matter here if you're using both types
 
yup, Kevin knows what's up
only numpy arrays (as opposed to lists) can be indexed with sequences
 
user10043886
@Kevin I see. But any idea why the return normalise(statevector[array_mask != 0]) executes fine?
 
I doubt that
both statevector and array_mask are arrays, I guarantee it
 
That program doesn't appear to be doing statevector = [3,4,6,8], so I wouldn't expect statevector to be a list in that case
 
7:36 PM
postselect(res_state.get_statevector(), 6, True)
first arg is statevector
 
user10043886
@Kevin Umm, so any idea what data type statetvector is ?
 
why not check that yourself?
 
user10043886
In the original program
 
you're the one with the code
 
If you're doing statevector = [3,4,6,8], its type is list. If you're doing statevector = round_to_zero(postselect(res_state.get_statevector(), 6, True), 1e-3), it's probably an array
 
user10043886
7:37 PM
@AndrasDeak How to?
 
print(type(res_state.get_statevector()))
 
user10043886
Trying, thanks
 
or, you know, just look at the API you're using and see what get_statevector returns knowing its class
 
I like to do both :-) read the docs, then do print(type(thing)) anyway, because Trust No One
 
and then just do statevector = np.array([3,4,6,8]) to start Making It Work
 
7:40 PM
I have trust issues ever since map() stopped returning lists
 
or statevector = np.asarray(statevector) if you already have an array-like by that name and want to make sure it's an array
 
user10043886
Traceback (most recent call last):
File "4x4_system.py", line 60, in <module>
print(type(res_state.get_statevector()))
NameError: name 'res_state' is not defined
 
dramatic_gopher.gif
 
user10043886
Traceback (most recent call last):
File "4x4_system.py", line 60, in <module>
print(type(statevector))
NameError: name 'statevector' is not defined
 
I suggest putting it in the original program where it works
I won't be able to help you at this level I'm afraid, you need to practice some basic python for a while
 
user10043886
7:44 PM
Oh, sorry. I put it in the wrong place
 
user10043886
Ah, so it seems that statevector is a numpy array
 
Ok, great. I think that's what we wanted it to be.
 
user10043886
And statevector[array_mask != 0] returns those elements of statevector which aren't 0's
 
user10043886
as a numpy array again
 
user10043886
Nice
 
user10043886
7:53 PM
Thanks!
 
8:05 PM
Hey, I have an existing function like so:
def call_cli_command(command, args, directory="", input_=False):
    """Execute CLI Command and get output as string."""
    final_command = command + " " + " ".join(args)
    # pdb.set_trace()
    if input_:
        p = subprocess.Popen(final_command, cwd=directory, shell=True, stdout=subprocess.PIPE, stdin=subprocess.PIPE)
        print "Do you want to kill all remaining processes (y/n): ",
        f = raw_input().strip()
        output = p.communicate(input=f)
    else:
        p = subprocess.Popen(final_command, cwd=directory, shell=True, stdout=subprocess.PIPE)
i just had to modify the path and the command to be run for a job ; and I created this, syntactically does it look ok would you say?
 command = "./qlogin"
    args = ['-cs rosesprcvlt01']
    directory = "E:/Program Files/CommVault/Simpana/Base"
    output = call_cli_command(command, args, directory)
 
an addendum to the weird open(0) stuff I asked about before, open(0).close() exits an interactive shell
 
im just wondering if the args looks ok, as the original args used grep between arguments, but i think this is one argument? -- and also i the spaces in the path are ok ; thats my two main queries
the original code looked like this:
command = "./bpdbjobs"
args = ['-report', '|', 'grep', '-i', 'Active', '|', 'grep', '-i', 'Restore']
directory = "/usr/openv/netbackup/bin/admincmd"
output = call_cli_command(command, args, directory)
 
cbg
 
cbg
 
8:13 PM
cbg
 
@Gary does it work? I'm not 100% sure what your question is
 
i can't test it as i dont have access to the system, so i just wanted to sanity check it before i send it off to the target system
 
you have to run code you can't test?
 
in this instance yes
i have to pass the script to someone else to run
the original code worked fine, i've just changed the path and the command and arguments, but i just wanted to check there were not any glaring mistakes in the few lines i had changed
 
pycharm does not seem to dislike the syntax
subprocess is defined elsewhere?
 
8:16 PM
ok thank you
 
I'd be worried about '-cs rosesprcvlt01' as one arg.
 
that's one of the things i was wondering about
 
I'd probably lean on the side of splitting them, as that's what the original does
 
' args = ['-cs', '|', 'rosesprcvlt01]
dies that look ok ?
'['-cs', '|', 'rosesprcvlt01']
im not sure if i need to leave the pipe in there or not
 
no, I'd imagine you don't want a pipe there
 
8:19 PM
['-cs', 'rosesprcvlt01']
so this you think?
 
cbg
 
cbg
 
did someone here worked with pyopengl on windows?
 
@Gary yeah, but my mental interpreter is missing the subprocess module so don't count on me.
Is it super important that this works on the first try?
 
I gone into problem - it doesnt see the glut dlls even though they're both in path and near .py file
 
8:21 PM
ha ok, thanks, appreciate you taking a look
 
same code works just fine on Debian
 
I'm not quite sure about python, maybe it handles it better than other cli scripts, but Windows can be hard when managing files calling one another from different drives.
 
Also please post code as text rather than images
 
im not sure that it is problem with code, but ok
 
I don't see anything in that traceback attempting to look for DLLs?
 
8:28 PM
I searched for questions at SO, and they say that I should have glut dlls near my py file
3
Q: Attempt to call an undefined function glutInit

Szabolcs DombiI need a glut window in python. I have the following exception using Python 3.5 and PyOpenGL.GLUT Traceback (most recent call last): File "D:\...\Test.py", line 47, in <module> if __name__ == '__main__': main() File "D:\...\Test.py", line 9, in main glutInit(sys.argv) File "C:\......

I downloaded glutdlls archive and put them both in directory that is in PATH, and near the file
this didnt affected anything
 
Ah, that's beyond my knowledge then sorry. I don't understand why having the DLLs "next to" your python script would solve the issue.
 
@MaxLunar what is baseplatform.py?
 
part of PyOpenGL I guess?
 
you could look at the possible duplicate link on the question you linked stackoverflow.com/questions/26700719/… some answerer specified that they had to delete the pip installed GLUT for this to work.
 
oh
lets try
 
8:43 PM
Please read the linked Q&A before :) I could very well be completely misunderstanding this
 
yes, I just have nothing to do, why not trying this way...
 
the stack trace in that other question is indeed very similar to your own
 
Yey, unofficial Windows binaries come to the rescue again :)
Once I switched to Anaconda they became something of a relic, but they really are the only way to get some things to work on Windows properly
 
user10043886
8:58 PM
There's a method named __init__([specs]) here. Any idea what it means?
 
user10043886
Especially I haven't seen methods of the form _init_
 
user10043886
93
Q: Why do we use __init__ in Python classes?

LostsoulI am having trouble understanding the Initialization of classes. What's the point of them and how do we know what to include in them? Does writing in classes require a different type of thinking versus creating functions (I figured I could just create functions and then just wrap them in a class...

 
user10043886
Oh, it's here
 
user10043886
Nvm
 

« first day (2824 days earlier)      last day (2127 days later) »