From 9f504c6bd6677bc4422de42417878293070d9fe2 Mon Sep 17 00:00:00 2001 From: Anthony Wang Date: Tue, 1 Sep 2020 11:56:58 -0500 Subject: [PATCH] print("Hello, world!") - Part 0 --- ...20-09-01-print-hello-world-part-0.markdown | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 _posts/2020-09-01-print-hello-world-part-0.markdown diff --git a/_posts/2020-09-01-print-hello-world-part-0.markdown b/_posts/2020-09-01-print-hello-world-part-0.markdown new file mode 100644 index 0000000..9f55be9 --- /dev/null +++ b/_posts/2020-09-01-print-hello-world-part-0.markdown @@ -0,0 +1,39 @@ +--- +layout: post +title: "print(\"Hello, world!\") - Part 0" +date: 2020-09-01 11:55:04 -0500 +author: Ta180m +tags: ["Programming"] +--- + +> *Your first podcast will be awful +> Your first video will be awful +> Your first article will be awful +> Your first art will be awful +> Your first photo will be awful +> Your first game will be awful +> But your first code will be perfect. +> Zero bugs and very clean code. +> It will be "Hello, world!"* + +For the past few years, "programming" and "C++" have been pratically synonymous for me. I knew about the wild world of other programming languages, but for the most part, I just stayed in my little C++ bubble. After all, for competitive programming, C++ is enough. + +But C++ has its limits. For [modeling infections diseases](https://github.com/Ta180m/Infectious-Disease-Modeling), its lack of easy-to-use scientifc and numerical libraries complicated my project, and I ended up using Python. And AP Computer Science, which should really be called *AP Java Language and Composition*, forced me to learn Java. (Although I think College Board should switch to Python for that course) And trying out a new programming language couldn't be easier, with loads of online tutorials and compilers such as [OnlineGDB](https://www.onlinegdb.com/). And if I want to actually run a language on my Ubuntu computer and do benchmarks, I can just `sudo apt install` it. + + +## So what is this project? + +This project is not meant to be an objective comparison of programming languages. Comparing programming languages with benchmarks is notoriously difficult, and there are already [great resources](https://benchmarksgame-team.pages.debian.net/benchmarksgame/) out there for that, so think of this project as more of a personal exploration of infinite universe of programming languages. (And don't take my "benchmarks" too seriously) + + +## So what are you going to do, anyways? + +This is were the pseudocode below comes into play: + + + +It contains everything to give a quick, high-level overview of a programming language: a recursive function definiton, an `if else` statement, an array or list, a `for` loop, and two nested loops through the array or list. The entire program has time complexity `O(N^2 log N)` of course, and with `N = 1000`, this runs at around a second in a typical programming language, allowing us to make some rough performance comparisons. (Although you really shouldn't take these measurements too seriously, as I said above) + +I already have it implemented in about 10 different programming languages so far, so I'll try to post a new part about my experience with each language every day. I'm aiming for at least 20 language, but we'll see. + +Anyways, check back tomorrow for C++!