« first day (2461 days earlier)      last day (2400 days later) » 

11:15 PM
@Neil crap I need to add that back in (although maybe for list - list)
 
How easy is JavaScript to learn? Discord bots are written in JavaScript, so I obviously must learn JavaScript...
 
If you know any other language, it's easy to start. But it's difficult to master.
 
mastery is not required to make a bot, i assume
 
Mastery is not required to make another language in it.
 
@SocraticPhoenix Discord bots are written in whatever.
I wrote mine in C#
 
11:25 PM
Javascript is regarded by particular CS professors as one of those languages everyone should learn, regardless of if it's good.
 
@ATaco I'd expect CS professors to lean more towards C/++ as a necessary language.
 
They are obviously also on that list of languages someone should learn, but JS is definitely on that list too.
 
@Pavel Java?
javajavajavajava
 
@SocraticPhoenix Sure, but C# is better in every way, and if you know Java you already know C#.
 
Anonymous
11:27 PM
@Pavel Fusion of two other usernames I used to use, given as a nickname by a friend who knew me as both.
 
@Pavel Fite me Java is best (but I don't know C# so I have no right to an opinion...)
 
Ah
 
There's a Lua Module for the Discord Bot API. Shame it's for LuaJIT, but it's there.
 
Anonymous
@SocraticPhoenix Quite a few Discord bots are written in Python
 
@Mego ooh I sorta know Python...
 
11:28 PM
Python is another language everyone should learn.
 
@SocraticPhoenix Basically, C# started as a Java clone, but then they kept adding features to make it awesome and the Java people didn't do that so much.
 
I know I'm going to learn C/C++ in college because I wanna do compilers and stuff
 
A discord bot would require a lot of networking-related calls, and C# is the only language with sane async syntax.
 
@Pavel u say that but have u used every language? (though java is just plain strange when it comes to threading synchronized and atomic and volatile and all that stuff I don't get).
 
C# is a pretty great language.
 
11:32 PM
I know 9 programming languages, Python, Java, and the 7 I made myself xD
 
//C# Async
async Task<int> foo() { return 5; }
var bar = foo();
Console.WriteLine(await bar);
Oh right, var allows you to omit the type of a variable if the compiler can determin it.
Threading in general is so much simpler.
 
What is the difference between Groovy and Java?
 
@MDXF Slightly different syntax, more expanisve stdlib, some additional features.
 
@Pavel Syntax differences?
 
I recommend Kotlin over Groovy, it aims to do the same thing, but does it better.
@MDXF Slightly. int[] array = [1,2,3]
 
11:36 PM
also kotlin can target jvm, javascript, or native, and has official android support
 
@Pavel Ah I see
@SocraticPhoenix Yeah Kotlin also has awesome operator overloading
 
@MDXF I really should learn kotlin
 
@SocraticPhoenix Or abandon the JVM entirely and use C#.
 
@SocraticPhoenix If you know Java that won't be hard
 
@MDXF I know some much Java that I understand how terrible it is, but still love it.... basically the point of no return
@Pavel But I know JVM Bytecode... I dunno assembly... and if I want (to make) a compiled language...
 
11:38 PM
@SocraticPhoenix You don't need assembly to use C#
 
You don't need to know JVM Bytecode to use java either, for that matter.
 
@SocraticPhoenix Yeah that's me with C, it takes forever to program things that would be simple in other languages, yet I love it's low-level-ness and ... everything else
 
I'll probably be forced to learn it eventually
 
Except memory management >.<
 
11:39 PM
^ why i don't want to learn C/C++
 
It's not that bad once you get used to it. But finding memory leaks is insanely difficult sometimes, even with valgrind.
 
63
Q: Differences between MSIL and Java bytecode?

user18055I'm new to .Net and I'm trying to understand the basics first. What is the difference between MSIL and Java bytecode?

 
But I have never done memory management...
 
(.NET bytecode is called MSIL)
 
@SocraticPhoenix It's less confusing than you think.
 
11:41 PM
@ATaco I assume so... I went into designing a practical programming language with a similar mindset (how does anything work), and came out with a functioning thingy... Thing is, I have to be forced to switch languages because otherwise I just do it the way I know how...
 
@SocraticPhoenix The key to memory management is: not malloc(size), but malloc(size * sizeof(variable type goes here)).
3
 
Only reason I learned python is because I had an internship in python...
despite saying that I wanted to learn python for at least 2 years before that...
 
@MDXF Or just calloc(size, sizeof(variable type goes here))
 
._. how did I never know that
I've even written my own implementation of calloc and I didn't know that
 
@MDXF You've been trolled by memory allocation! How does it feel?
 
11:43 PM
>_>
 
It's basically just #define calloc(a,b) malloc((a)*(b))
 
TIL that The Common Language Runtime (C#'s VM) supports global functions and tail call optimization, though no CLR language actually uses these features.
MSIL is designed to be human writeable/readable, so it's possible write a function that uses tail-call optimization in it and then call it from C#.
 
@MDXF not if you do it properly
 
Define "properly"
 
@Pavel :| such a waste
@MDXF remembering to put in all your frees
 
11:50 PM
@ASCII-only why? This means C# could easily support these features in the future.
 
@ASCII-only No, memory leaks as in printf("%p",pointer); causing a segmentation fault.
 
Or just using C++ and having no memory management
 
@Pavel A waste because no one uses them...
 
@MDXF also not doing things like that
 
Wait, is groovy interpreted?!?
@ASCII-only >.<
 
11:51 PM
@MDXF it's JVM...
 
@SocraticPhoenix BRB writing .net language to use them.
 
Yeah but it doesn't have (or maybe it doesn't need) a main
 
@Pavel lol, really?
 
no
 
11:51 PM
@MDXF who needs main tho
 
it's a TNB joke
@SocraticPhoenix compiled languages :P
 
@Pavel just make a Roslyn extension...
 
I wanna make a compiled language -_-
 
@MDXF the stuff not in a method is packed into a main by the compiler.
 
My favourite all time bug, "Why is this pointer NULL?", followed by "Why is this pointer 0xBAADF00D"
 
11:51 PM
@Pavel Ah I see
 
@ASCII-only sure
 
Bitwise does that
except it's interpreted ._.
 
@MDXF luckily VSL is an exception
 
@ASCII-only well, as I said before, some sort of filtering would be nice
 
Odd
 
11:52 PM
@Neil oh yeah forgot about that >_> sorry
 
so that I can write Filter([1, 2, 3], Minus(i, 1)) for a similar result
 
@SocraticPhoenix yes, actually. I've been working on it for a few weeks, it's called Safire due to the ruby-like syntax
 
The only problem I have with python is how u run a script... if __name__() == "__main__" or whatever it is is evil
@Pavel kewl
 
(obviously in reality the list and function wouldn't be hardcoded like that)
 
@SocraticPhoenix It's also dynamically typed. I am going through extreme amounts of pain in order to make var foo = Console.WriteLine work, since methods and Delegates (lambdas) can't be assigned to variables of type dynamic without a ton of magic.
And it's the worst kind of magic, reflection magic. stackoverflow.com/a/46782035/3553138
At least the CLR supports a dynamic type, JVM doesn't iirc.
 

« first day (2461 days earlier)      last day (2400 days later) »