« first day (2219 days earlier)      last day (2730 days later) » 
00:00 - 22:0022:00 - 00:00

10:01 PM
Yeah 2d rotations is just complex multiplication
Translation is complex addition
The math is really nice
Much nicer than the matrix isomorphism
 
im actually reading about it. Kind of hard to understand but it seems similar to a scalar multiplication
 
Complex or quaternion?
Quaternions are difficult
 
quaternion but im an absolute noob so xD
 
Yeah it's 4D space so it's hard to understand
 
By the way, why dont all math classes have programming integrated? seriously, I learned so much ever since im learning at programming school in zürich
Now since im programming ive wanted to learn all the math I thought was boring at school
 
10:07 PM
Idk I feel like a lot of time would've been wasted in my math classes if we had programming assignments too
 
Due to the fact that it is so much more interactive I believe all those concepts can be much better understood and memorized
@Meredith actually thats true as well
 
Especially the early classes like calculus
Programming wouldn't really help that
 
You are absolutely right there.
 
+ it'd probably be in something awful like matlab
 
@Meredith matlab is more for scientific purposes anyways and for math / physics fanatics
But matlabs works. I tried it once its kinda cool
 
10:13 PM
Matlab sucks
Like you said it's for math people who don't have any programming experience
So the whole thing is just cancerous if you've used literally any other programming language before
Also I my linear algebra professor used to send us code snippets in lisp
I'm cool with functional programming now, but I wasn't when I took linear and it was awful
 
@Meredith Wait, you actually had a math teacher who sent you code snippets is freakin lisp? No wonder you are so against it xD
lisk and haskell are horrible languages
 
Lisp isn't that bad
It's just for old people
 
haha, @FlorianMargaine is an old person
 
He is isn't he
Dude's like 40
 
omg please. The code in lisp and haskell is so so so ugly.
 
10:18 PM
That's functional programming for you
 
Also, lisp, in other forms, is still in use.
e.g. Clojure.
 
@Asperger Lisp isn't ugly, C-like is
We're just more used to it because of reasons.
 
Without an ide or other code editor that does syntax highlighting its hard to distinguish what everything does
 
I like the look of c-like, but I suspect that is because of my personal history with code.
 
@Asperger That's true for pretty much any language.
 
10:19 PM
Good thing I always have syntax highlighting
 
@MadaraUchiha I think C derived languages have this sort of human touch.
There is more order, definition or lets syntactic beauty
 
@Meredith ...
 
@MadaraUchiha would you ever want to rewrite a complex oo programm in haskell syntax?
 
@Asperger Of course not, Haskell isn't OO
 
I would happily rewrite a huge OO program in haskell
 
10:22 PM
But with Common Lisp's CLOS? I'd consider.
 
I'm not even 30...
 
same reason you don't use Visual Basic to do functional programming
 
@MadaraUchiha and thats one issue
 
@FlorianMargaine I assumed you were older because you use lisp
 
@FlorianMargaine There there, grandpa. It's going to be alright.
 
10:22 PM
I'm the old one. I turned 37 on election day.
 
@Asperger It's an issue for you
You find OO the most comfrotable way of creating abstraction
 
But really though
 
But Haskell offers different tools
So does Lisp
 
Haskell's syntax is a mess
 
I find lisp to be () heavy, but I could get used to it if I did it more.
 
10:23 PM
I wanted to get into clojure but then I discovered elixir
 
@Luggage And I find C-like to be {} heavy
vOv
@Meredith Clojure is nice
 
c doesn't need {} around every expression
 
ugh
rust is so verbose
 
But.. I acknowledge the what we all find pretty / ugly is based on our experiences.
 
I'm not sure what the difference between lisp and clojure is
Besides the jvm
 
10:25 PM
Think about it one step higher in the abstraction stack
 
@Meredith it's like PHP and Javascript
 
Why do we even have the concept of "files"?
 
That's it. Very similar languages on a different runtime. I think
 
Directories and files were invented to mimic the real world
 
they're kinda similar, but a lot of differences
 
10:25 PM
Seriously I doubt anyone would want to write a complex media player program using haskell
 
But it doesn't make a lot of sense in a virtual space
 
filesystems are just a key-value store.
 
Surely there's a better abstraction?
 
@Asperger More things like that need to be written in functional languages
 
haskell is good for the science department
 
10:26 PM
A lot of people are creating side-effect heavy apps in functional javascript
 
@Meredith The language
 
But we take it as granted, because that's what we grew up with
 
It works really well
 
or maybe im just freaking scared to master haskell, either way I thought the syntax was nasty
 
@Meredith A lot of people say that they're using functional programming because they use map and filter
 
10:27 PM
Yeah it's not functional until you have a 100 line reducer
 
@Zirak they need to stay on the ground lol
 
@Asperger Who cares, you get over syntax after a few hours
Don't be hatin' on something if you've tried it for an hour tops
 
functional in JavaScript sucks
 
I like F#. I have never used it for anything 'real', just played, but I come from a C# background so the .NET environemnt is familiar, and it was a good intro to funciton programing for me.
 
Similarly, don't be boasting something if you've got an hour's experience in it
 
10:28 PM
I have 2 hours, ty.
 
Try finding your code in a stack trace with 10 composed, partially applied functions.
 
@MadaraUchiha Immutable.js makes it a little nicer but yeah there's a lot of room for improvement
 
@Zirak I know but I managed to pick up sql, c, javascript, java, C# and php but haskell I just cant manage to pick it up
 
currently looking for a C build system...
 
@Meredith Immutable.js is by no means a functional library.
Immutable.js is a data-structure library
 
10:29 PM
And?
 
there is something about haskell that makes it hard
 
It makes writing functional code easier
What's your point?
 
@Asperger So you've managed to pick a bunch of languages with very similar abstractions and syntax, wow-wee
 
@Meredith No it doesn't...
 
@Zirak its normal, all c derived not a big deal xD
 
10:30 PM
Ok...
 
(also, writing complex C is super hard, so it's impressive if you managed to really understand C)
 
It gives you immutable data structures, which are equally useful in OO and in FP
 
So it's useful for FP
Literally what I'm saying
 
@Meredith ...
 
I use bare metal erlang.
 
10:30 PM
@Asperger Haskell's a different language than what you've experienced so far, and that's fine. There are lots of different languages.
 
That's like saying that JS is a functional language
 
Like Erlang and F#, as @Luggage said
 
Just because you can write some things in a functional style, doesn't make it functional
 
@Asperger try Prolog one day. It's fun too.
 
Ramda is a functional library
 
10:31 PM
Is JS not a functional language?
You can write functional code in it
 
No, but it can be used as such
 
Not every language has exactly 1 paradigm
 
@Meredith You can write functional code in Java too
 
@Zirak C is cool, especially in the embedded world. For example playing around with the stm32f4
 
Does it make Java functional?
How about C? You can pass function pointers in C
 
10:31 PM
technically even c can be functional, but passing around funciton pointers will be annoying
 
If you use it that way then obviously yes
Are you drunk right now lol
 
@Meredith Neither Java nor C are functional languages.
 
I am. What of it?
 
Im a fan of pointers, im not even sure if haskell has them.
 
If you write functional code, then the code is functional
 
10:32 PM
Nor is JavaScript, by the way.
 
Seriously wtf are you trying to say
 
@Meredith But the language isn't.
 
@Asperger what would that be useful for?
 
@MadaraUchiha they have components. Java has maps and lambdas for example
 
What paradigm is JS then?
 
10:33 PM
@MadaraUchiha but lanbad expressions make using functional techiniques a little less ugly.
lambda*
 
its not a functional language though
 
Cuz it can't be OO, it can't be imperative...
 
@Luggage Sure, that's true.
But can you say that Java is a functional language?
 
No. I'm not arguing with you. I Agree
 
some c languages merely adopted some functionality. Let, lamdas etc is one of them
 
10:33 PM
No, it's an OO language with (very) few functional elements in it.
 
If you can write functional code, then it supports FP
 
In C there aren't even functional elements, it's just abuse.
 
Wtf
 
Those aren't functional languages but have varying degrees of which function techniques can be convenient.
 
Yes ^
 
10:34 PM
ES6 made it a little les painful
 
C# has some good bits for functional, too.
 
And on the same token, libraries that can be used in functional code, aren't automatically functional by definition.
 
what's a functional language, really?
a language with functions?
 
Literally all I said is that immutable.js makes FP easier in javascript
 
10:35 PM
A languages made with that paradigm as the primary one?
 
I have an iterator and I want to iterate in the reverse order. Is the only good option Array.from(iterator).reverse() ?
 
Like holy shit how are you trying to argue against that at all
Wtf are you on
 
@Luggage I prefer "a language with functions"
 
One of the coolest languages ive ever used for my last project was swift
seriously swift is awesome as is google dart
 
@Meredith agree.. specifically staying 'immutable'.
which is a part of it
 
10:36 PM
Writing a functional app with native js fucking sucks
Obviously immutable makes it easier
 
but if I look back at haskell I think: darn, thats some pretty ugly scripting language
"scripting"
 
@Waterscroll I think so, yes. I can't imagine any way to reverse an iterator without reading in all and then reversing thee results.
 
That doesn't fucking change because you can use immutable data structures in OO
 
@Meredith true
 
Lambda functions also don't make FP easier because you can use them in imperative programming
 
10:38 PM
@Asperger as you get used to the 'functional way of thinking' the synta makes more sense
matching, etc.
 
Fuck off with that shit
 
I think pure JS is not adequate for pure Functional nor pure OO.
 
Why so angry?
It's adequate, but not ideal, in my opinion.
 
@Luggage can you give me reasons why functional programming makes me a better programmer?
its a serious question, I want to know what benefit I have
 
A programmers job is to solve problems and knowing a different way to approach them makes you a better programmer. I know that's vague, but I don't know of anything more specific.
Some problems fit better for functional languages or patterns. Some work better with OOP
 
10:39 PM
I know a benefit. Be able to read and understand functional code if you have to.
 
some with declarative, etc, etc.
 
I though: lambdas and co were the only good thing about functional languages
the rest was trash
 
FP is great if you have a mathematical model for what you're doing
 
^ is part of it, yes
it's not 'trash' it's just not a silver bullet. Nothing is.
 
But there are always pros and cons between languages. You could essentially communicate with haskell during runtime to solve certain tasks faster
agar.io some parts are based on haskell
they used it for their mathematical model because its damn fast
 
10:44 PM
I care more about the API than the paradigm and programming language. I want draw UI without importing tons of libraries that are not portable. JS allows em that and I am happy. But, if I could change the language I would remove a bunch of stuff from the old days and make a pragma that indicates you are using only the new stuff. Instead of 'use strict'; something like 'use js v2';
 
@Waterscroll I kind of think that way too, especially since im a library hater
 
'a library hater'?
So you also refuse to use tools like screwdrivers, too. You make everything from rocks? :)
 
Thats why after working a lot with JavaFX and with microsofts NET framework, I decided ti make my own graphics library with openGL
@Luggage ok ok, not entirely. I do use the standard libraries :D
 
You mean, you made opengl bindings for .net?
 
but only standard stuff!
 
10:47 PM
One time I needed a library to check if a point was in a polygon. The library for that was 200mb of C++ code. I am not against libraries, but I don't like when you have too many dependencies that are too bug. Sometimes they break and your code break with them.
 
That's a pretty extreme example.
You made your own straw man.
 
I used to dislike libraries when I first started because it felt like cheating
And tbh it almost is
But I'm more than happy to cheat now
 
@Asperger no, there are faster "languages"
haskell is just better suited to write math-heavy code, is all
 
@Waterscroll I had a script that did that in AHK
Aaaaages ago
 
Kind of feel you
 
10:49 PM
it's not cheating. Also there are a wide range of libraries. Some small, well constructed. Other larger, bloated piles of ulities that you can easily re-create.
You need to evalutate them on a case-by-case basis
sometimes a library provides something you you can't replicate with years of work.
Sometimes you are truely better off without it.
 
Dependencies really suck. In c++ I need to use event handling libraries and you have no idea how it drives me insane
 
"event handling"?
 
I am not against libraries. I am kind of against importing tons and tons of code that make your code either hard to maintain or not as portable as you wish.
 
left-pad
That was a trip
 
posted on November 12, 2016 by Axel Rauschmayer

An ES6 proxy lets you intercept and customize operations performed on an object, its so-called target. Interception and customization is handled via a handler object (think even listener). Operations are intercepted by handler methods. If a handler method is missing, the corresponding operation is simply forwarded to the target. Therefore, if the handler is the empty object, the proxy should

 
10:51 PM
If a programmer of mine was spending his time re-inventing wheels because he or she couldn't handle dependences or just thought it was 'cheating' if they didn't do it all from scratch, I'd have to have a talk with them.
 
@Florian Indeed. In C there is no event listener implementation
 
ah, that
 
so you need to either create your own implementation with 1000+ lines of code or get a library
 
@Waterscroll yea. Sometimes the choice to include some 3rd party code can be based on "could I maintain this if I had to, if it gets abandoned"
 
... 1000+ lines of code?
 
10:51 PM
indeed
 
you're doing C wrong if you need 1000+ lines of code to write basic event handling.
 
Not basic but complex listeners
 
fancy events
 
Jesus, kind of feels like working with Vulcan where I needed 3000 lines of code for animating a polygon
 
10:53 PM
@FlorianMargaine and then there is wolfram... but that'd be something else.
 
^ fancy events
 
2d polygon by the way XD
By the way, if you havent checked out the vulkan api yet:
hundreds of code lines just for a simple 2d triangle. Absolutely worth it though. C and C++ for now.
@Luggage event more fancy trumpdonald.org
 
Will node functions one day return promises?
 
Not sure, but you can just use something like Bluebirds .promisifyAll() to get it now.
 
On github how do you know which JS file to use?
which file do i download to use require(thatFile.js) with?
 
11:01 PM
None. install it with npm
 
its not on node
 
it may be multiple files.
 
isnt npm mostly for node
 
both, but you are right, it's not configured right to be an npm module
looks like it's pre-build and put into dist/
 
you can use it for personal cloud storage
just don't tell anyone
 
11:03 PM
so like dist/index.js?
 
yea. or the minimized vrsion.
it needs better instructions. it's not clear.
that thin redefines require().
it's junk. don't use it
first line of the index.js: require=(function e(t,n,r){fu
 
your saying not to use the module at all?
like i shouldn't trust it
I appreciate that advice
 
the package.json has no "main". It's not a standard module type. They make their own require() to pretend it's a moduel that'll cooperate with others, but it isn't
 
I see
odd
 
are you using it on node or browser?
 
11:07 PM
browser
 
you have options.
hm.. are you using webpack or something like that?
or browserify?
 
no the directions say this should work with the browser: at the very bottom of github.com/lalalic/docx2html
 
Yea, but thier browser build is junk, so I am trying to give you another option
so, answer my question, please
 
I know that browserify is a tool for taking node based projects and using them in the browser but I've never used it. I've never even heard of webpack. Sorry for the lack of knowledge.
 
so 'no'?
 
11:12 PM
right no
I just use require to manage my modules
so far its been good enough
 
ok. they used browserify to build it, but they built it as if it's the whle application. It trumps require() which will break some other libraries.
require.js?
 
yeah require.js
 
yea.. so it'll redefine require() and break that.
 
ill just go back to trying to figure out how to use mammoth instead
it does what i want in terms of conversions but i need to figure out how to use it in the browser
 
This library can be used if you are willing to put in a small amount of effort. Clone it and try to bruild it with browserify yourself (it's configured for that) but use the "library" option.
 
11:14 PM
sounds tough since I don't have experience with browserify
I appreciate the help btw ill see if i can get mammoth to working and maybe ill check back if i cant
 
Has anyone use node csvtojson recently?
I used it less than two weeks ago but its not working now, giving me this error: TypeError: this.parser.on is not a function
Looking at the file where the error came from shows that its csvtojson itself that is breaking, and I haven't changed the code I made since the last time I used it (except for changing the csv source)
 
did you update your csvtojson version?
 
git clone github.com/lalalic/docx2html.git
cd docx2html
npm install
npm run build
node_modules/browserify/bin/cmd.js -v -d -s docx2html -r ./lib:docx2html -o dist/index.js -i jquery
@COMisHARD ^
that builds a UMD that is compatible with require.js as dist/index.js
 
I've tried updating csvtojson but it has not had an update in those two weeks, its still the same version
 
What are your thoughts on the ternary operator? I had a professor that was against its use, but it is kind of convenient.
 
11:34 PM
it's fine if not abused
abused = nesting them or anything that's hard to read
In other words, use it when it's short and readable, avoid it when it's not.
 
I have seen it nested and broke in more than one line. Very hard to read indeed.
 
that's the only rule. Avoid things that cause confusion.
var text = messages.length ? "You have new messages." : "No new messages";
Nothing wrong with that ^.
 
Yes
 
00:00 - 22:0022:00 - 00:00

« first day (2219 days earlier)      last day (2730 days later) »